Refactor Projects component to use custom Button component for loading more projects
This commit is contained in:
parent
d7475dc0eb
commit
44fa39d3dc
1 changed files with 4 additions and 3 deletions
|
|
@ -1,6 +1,7 @@
|
||||||
"use client";
|
"use client";
|
||||||
import { SquareArrowOutUpRight } from 'lucide-react';
|
import { SquareArrowOutUpRight } from 'lucide-react';
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
|
import { Button } from './ui/button';
|
||||||
|
|
||||||
const projects = [
|
const projects = [
|
||||||
{
|
{
|
||||||
|
|
@ -66,12 +67,12 @@ export default function Projects() {
|
||||||
))}
|
))}
|
||||||
</div>
|
</div>
|
||||||
{visibleCount < projects.length && (
|
{visibleCount < projects.length && (
|
||||||
<button
|
<Button
|
||||||
onClick={() => setVisibleCount(visibleCount + 3)}
|
onClick={() => setVisibleCount(visibleCount + 3)}
|
||||||
className="mt-6 px-4 py-2 bg-muted text-muted-foreground rounded font-medium text-sm hover:bg-muted/80"
|
className="mt-6 bg-muted text-muted-foreground rounded font-medium text-sm hover:bg-muted/80"
|
||||||
>
|
>
|
||||||
더 불러오기
|
더 불러오기
|
||||||
</button>
|
</Button>
|
||||||
)}
|
)}
|
||||||
</section>
|
</section>
|
||||||
);
|
);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue