{/* Shop By — left half */}
Shop By
{shopBy.length > 0 ? (
{shopBy.map((item) => (
{item.name}
))}
) : (
No categories available
)}
{/* Top Rated — right half */}
Top Rated
{loading ? (
{Array.from({ length: 4 }).map((_, idx) => (
))}
) : topRated.length > 0 ? (
{topRated.map((product, idx) => (
{product.image ? (
) : (
No Img
)}
{product.name}
{product.oldPrice != null && (
{formatCurrency(product.oldPrice)}
)}
{formatCurrency(product.price)}
))}
) : (
No top rated products
)}
);
};
export function isTopDealsNavLabel(label: string): boolean {
const n = label.toLowerCase().replace(/\s+/g, '');
return (
n.includes('topdeal') ||
n === 'deals' ||
n.includes('top-deals') ||
label.toLowerCase().includes('top deals')
);
}