feat: implement handle favorite units

This commit is contained in:
2025-04-30 12:25:06 +05:00
parent 8af3ed8f5e
commit cf6aabdaff
3 changed files with 50 additions and 4 deletions
+8 -1
View File
@@ -4,8 +4,10 @@ import { projects } from '../data/projects';
import Select from '../components/ui/Select';
import Button from '../components/ui/Button';
import ChartIcon from '../components/icons/ChartIcon';
import { useFavorites } from '../stores/useFavorites';
import UnitCard from '../components/UnitCard';
function FavouritesPage() {
const { units } = useFavorites();
return (
<div className='flex flex-col gap-6'>
<div
@@ -40,6 +42,11 @@ function FavouritesPage() {
<p className='text-m leading-0'>Compare</p>
</Button>
</div>
<div className="2xl:grid-cols-4 md:max-2xl:grid-cols-2 grid 2xl:gap-[1.111vw] gap-4 py-6">
{units.map((unit) => (
<UnitCard key={unit.id} {...unit} />
))}
</div>
</div>
</div>