Skip to content

Commit

Permalink
art
Browse files Browse the repository at this point in the history
  • Loading branch information
cnnmon committed Aug 16, 2024
1 parent 5795fc2 commit 48430d9
Show file tree
Hide file tree
Showing 3 changed files with 51 additions and 28 deletions.
9 changes: 4 additions & 5 deletions pages/art.jsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import artSections from '../utils/art.json'
import Image from 'next/image'

function Section({ section }) {
const { title, list } = section;

Expand All @@ -19,14 +20,12 @@ function Section({ section }) {
<p>[<span dangerouslySetInnerHTML={{ __html: autolink(art.title) }} />]</p>
<div className="flex w-full justify-between gap-2">
{art.images.map((image, imgIndex) => (
<img
<Image
key={imgIndex}
src={image}
alt={art.title}
style={{
width: `calc(100% / ${art.images.length})`,
height: 'auto'
}}
width={art.width}
height={art.height}
/>
))}
</div>
Expand Down
Binary file added public/images/fred.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
70 changes: 47 additions & 23 deletions utils/art.json
Original file line number Diff line number Diff line change
@@ -1,50 +1,74 @@
[
{
"title": "3d art (blender)",
"title": "2d art (procreate)",
"list": [
{
"title": "my ass!!!",
"images": ["/images/cat.gif"]
"title": "me on a bike",
"images": ["/images/bike.png"],
"width": 400,
"height": 400
},
{
"title": "digital upload",
"images": ["/images/digitalupload.gif"]
"title": "illustrations for https://www.kernelmag.io/",
"images": [
"/images/irena.png",
"/images/zora.png"
],
"width": 400,
"height": 100
},
{
"title": "cat cafe",
"images": ["/images/catcafe.gif"]
"title": "summer",
"images": ["/images/summer.png"],
"width": 600,
"height": 400
},
{
"title": "peppermint",
"images": ["/images/peppermint.gif"]
"title": "meditation study",
"images": ["/images/meditation.png"],
"width": 500,
"height": 400
},
{
"title": "me but online",
"images": ["/images/online.png"],
"width": 500,
"height": 400
}
]
},
{
"title": "2d art (procreate)",
"title": "3d art (blender)",
"list": [
{
"title": "me on a bike",
"images": ["/images/bike.png"]
"title": "fred",
"images": ["/images/fred.gif"],
"width": 300,
"height": 400
},
{
"title": "illustrations for https://www.kernelmag.io/",
"images": [
"/images/irena.png",
"/images/zora.png"
]
"title": "my ass!!!",
"images": ["/images/cat.gif"],
"width": 500,
"height": 400
},
{
"title": "summer",
"images": ["/images/summer.png"]
"title": "digital upload",
"images": ["/images/digitalupload.gif"],
"width": 500,
"height": 400
},
{
"title": "meditation study",
"images": ["/images/meditation.png"]
"title": "cat cafe",
"images": ["/images/catcafe.gif"],
"width": 500,
"height": 400
},
{
"title": "me but online",
"images": ["/images/online.png"]
"title": "peppermint",
"images": ["/images/peppermint.gif"],
"width": 500,
"height": 400
}
]
}
Expand Down

0 comments on commit 48430d9

Please sign in to comment.