Refactor: Implement Code Splitting

This commit is contained in:
gpt-engineer-app[bot]
2025-10-21 18:31:08 +00:00
parent da0f01a785
commit 70a8534da7
9 changed files with 722 additions and 89 deletions

View File

@@ -4,7 +4,7 @@ import { Label } from '@/components/ui/label';
import { Badge } from '@/components/ui/badge';
import { Button } from '@/components/ui/button';
import { Image as ImageIcon, ImagePlus, X } from 'lucide-react';
import { UppyPhotoUpload } from './UppyPhotoUpload';
import { UppyPhotoUploadLazy } from './UppyPhotoUploadLazy';
import { getCloudflareImageUrl } from '@/lib/cloudflareImageUtils';
export type ImageType = 'logo' | 'banner' | 'card';
@@ -125,7 +125,7 @@ export function EntityImageUploader({
</Button>
</div>
<p className="text-sm text-muted-foreground">{spec.description}</p>
<UppyPhotoUpload
<UppyPhotoUploadLazy
onUploadComplete={(urls) => handleUploadComplete(type, urls)}
maxFiles={1}
variant="compact"