eeeee
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
import { Suspense } from "react";
|
import { Suspense } from "react";
|
||||||
import Dashboard from "@/components/dashboard/dashboard";
|
import Dashboard from "@/components/dashboard/dashboard";
|
||||||
import { Metadata, Viewport } from "next";
|
import { Metadata, Viewport } from "next";
|
||||||
import PromotionsList from "@/components/dashboard/promotions/PromotionsList";
|
import dynamic from "next/dynamic";
|
||||||
import PromotionsPageSkeleton from "@/components/dashboard/promotions/PromotionsPageSkeleton";
|
import PromotionsPageSkeleton from "@/components/dashboard/promotions/PromotionsPageSkeleton";
|
||||||
import { Ticket } from "lucide-react";
|
import { Ticket } from "lucide-react";
|
||||||
|
|
||||||
@@ -20,6 +20,10 @@ export const viewport: Viewport = {
|
|||||||
};
|
};
|
||||||
|
|
||||||
export default function PromotionsPage() {
|
export default function PromotionsPage() {
|
||||||
|
const PromotionsList = dynamic(() => import("@/components/dashboard/promotions/PromotionsList"), {
|
||||||
|
loading: () => <PromotionsPageSkeleton />
|
||||||
|
});
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Dashboard>
|
<Dashboard>
|
||||||
<div className="space-y-6">
|
<div className="space-y-6">
|
||||||
|
|||||||
@@ -32,9 +32,10 @@ import { toast } from '@/components/ui/use-toast';
|
|||||||
import { Badge } from '@/components/ui/badge';
|
import { Badge } from '@/components/ui/badge';
|
||||||
import { Promotion } from '@/lib/types/promotion';
|
import { Promotion } from '@/lib/types/promotion';
|
||||||
import { fetchClient } from '@/lib/api';
|
import { fetchClient } from '@/lib/api';
|
||||||
import NewPromotionForm from './NewPromotionForm';
|
import dynamic from 'next/dynamic';
|
||||||
import EditPromotionForm from './EditPromotionForm';
|
const NewPromotionForm = dynamic(() => import('./NewPromotionForm'));
|
||||||
import PromotionDetailsModal from './PromotionDetailsModal';
|
const EditPromotionForm = dynamic(() => import('./EditPromotionForm'));
|
||||||
|
const PromotionDetailsModal = dynamic(() => import('./PromotionDetailsModal'));
|
||||||
|
|
||||||
export default function PromotionsList() {
|
export default function PromotionsList() {
|
||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
|
|||||||
8
package-lock.json
generated
8
package-lock.json
generated
@@ -63,7 +63,7 @@
|
|||||||
"zod": "^3.24.1"
|
"zod": "^3.24.1"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@next/bundle-analyzer": "^15.4.1",
|
"@next/bundle-analyzer": "^15.4.6",
|
||||||
"@tailwindcss/typography": "^0.5.16",
|
"@tailwindcss/typography": "^0.5.16",
|
||||||
"@types/lodash": "^4.17.16",
|
"@types/lodash": "^4.17.16",
|
||||||
"@types/node": "^22",
|
"@types/node": "^22",
|
||||||
@@ -861,9 +861,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@next/bundle-analyzer": {
|
"node_modules/@next/bundle-analyzer": {
|
||||||
"version": "15.4.1",
|
"version": "15.4.6",
|
||||||
"resolved": "https://registry.npmjs.org/@next/bundle-analyzer/-/bundle-analyzer-15.4.1.tgz",
|
"resolved": "https://registry.npmjs.org/@next/bundle-analyzer/-/bundle-analyzer-15.4.6.tgz",
|
||||||
"integrity": "sha512-O5R3iPLR3/oQWFIXl+Mnd02IyhvWBterTlXcceIGw29QHWL/gjvyO0eIVEvrJPS7zzE6/NSu1TiSVgi8mxotlw==",
|
"integrity": "sha512-LZWqTQgIpfhblT77VVc1r4qtHJY1pfZOAIx8zNtliU7L3pMjpNrG4rYWikJ7AyAI/RgYyt2sCVWqkeOZmFp7Zg==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|||||||
@@ -72,7 +72,7 @@
|
|||||||
"zod": "^3.24.1"
|
"zod": "^3.24.1"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@next/bundle-analyzer": "^15.4.1",
|
"@next/bundle-analyzer": "^15.4.6",
|
||||||
"@tailwindcss/typography": "^0.5.16",
|
"@tailwindcss/typography": "^0.5.16",
|
||||||
"@types/lodash": "^4.17.16",
|
"@types/lodash": "^4.17.16",
|
||||||
"@types/node": "^22",
|
"@types/node": "^22",
|
||||||
|
|||||||
Reference in New Issue
Block a user