2021-05-01 01:15:09 -05:00
|
|
|
import PButton from "./page-button";
|
|
|
|
|
2022-09-25 13:52:56 -05:00
|
|
|
export default function ProjectBlock({ local, pages }) {
|
|
|
|
if (local) {
|
|
|
|
return (
|
|
|
|
<nav>
|
|
|
|
<div className="flow space-y-4">
|
|
|
|
{Object.keys(pages).map((page) => (
|
|
|
|
<PButton
|
|
|
|
local={true}
|
|
|
|
key={page}
|
|
|
|
title={page}
|
|
|
|
images={pages[page].images}
|
|
|
|
url={pages[page].url}
|
|
|
|
new_tab={Boolean(pages[page].new_tab)}
|
|
|
|
/>
|
|
|
|
))}
|
|
|
|
</div>
|
|
|
|
</nav>
|
|
|
|
);
|
|
|
|
} else {
|
|
|
|
return (
|
|
|
|
<nav>
|
|
|
|
<div className="flow space-y-4">
|
|
|
|
{Object.keys(pages).map((page) => (
|
|
|
|
<PButton
|
|
|
|
key={page}
|
|
|
|
title={page}
|
|
|
|
images={pages[page].images}
|
|
|
|
url={pages[page].url}
|
|
|
|
new_tab={Boolean(pages[page].new_tab)}
|
|
|
|
/>
|
|
|
|
))}
|
|
|
|
</div>
|
|
|
|
</nav>
|
|
|
|
);
|
|
|
|
}
|
2021-05-01 01:15:09 -05:00
|
|
|
}
|