import { Card, Skeleton } from "antd"; import useBreakPoint from "hooks/useBreakPoint"; import styles from "./MenuSkeleton.module.css"; interface MenuSkeletonProps { categoryCount?: number; itemCount?: number; variant?: | "default" | "minimal" | "detailed" | "categories-only" | "menu-only"; } const MenuSkeleton = ({ categoryCount = 8, itemCount = 8, variant = "default", }: MenuSkeletonProps) => { const { isMobile, isTablet } = useBreakPoint(); const getCategoryCardStyle = () => { if (isMobile) { return { width: 90, height: 110, }; } else if (isTablet) { return { width: 120, height: 110, }; } else { return { width: 140, height: 160, }; } }; const getMenuItemCardStyle = () => { if (isMobile) { return { height: 140, padding: "12px 12px 12px 16px", }; } else if (isTablet) { return { height: 160, padding: "16px", }; } else { return { height: 180, padding: "20px", }; } }; const getCategoryImageStyle = () => { if (isMobile) { return { width: 90, height: 78, borderTopLeftRadius: 8, borderTopRightRadius: 8, }; } else if (isTablet) { return { width: 120, height: 78, borderTopLeftRadius: 8, borderTopRightRadius: 8, }; } else { return { width: 140, height: 78, borderTopLeftRadius: 8, borderTopRightRadius: 8, }; } }; const getMenuItemImageStyle = () => { if (isMobile) { return { width: 90, height: 95, }; } else if (isTablet) { return { width: 120, height: 120, }; } else { return { width: 140, height: 140, }; } }; return ( <> {/* Restaurant Header Skeleton */}