Files
zellyy-finance/src/components/BudgetCategoriesSection.tsx
gpt-engineer-app[bot] ae391e606b Refactor: Split Index page
Refactor Index.tsx into smaller, more manageable components.
2025-03-15 02:23:57 +00:00

33 lines
771 B
TypeScript

import React from 'react';
import BudgetCard from '@/components/BudgetCard';
interface BudgetCategoriesSectionProps {
categories: {
title: string;
current: number;
total: number;
}[];
}
const BudgetCategoriesSection: React.FC<BudgetCategoriesSectionProps> = ({ categories }) => {
return (
<>
<h2 className="text-lg font-semibold mb-3 mt-8"> </h2>
<div className="grid gap-4 mb-8">
{categories.map((category, index) => (
<BudgetCard
key={index}
title={category.title}
current={category.current}
total={category.total}
color="neuro-income"
/>
))}
</div>
</>
);
};
export default BudgetCategoriesSection;