1
Fork 0
mirror of https://github.com/Steffo99/unisteffo.git synced 2024-11-22 16:04:21 +00:00

Add temporary Image component

This commit is contained in:
Steffo 2021-07-11 10:19:41 +02:00
parent e151b74be5
commit 18f2a45982
Signed by: steffo
GPG key ID: 6965406171929D01
2 changed files with 18 additions and 0 deletions

15
src/components/Image.js Normal file
View file

@ -0,0 +1,15 @@
import React from "react"
import {Anchor, Paragraph} from "bluelib/lib/components"
import Style from "./Image.module.css"
import classNames from "classnames"
export default function Image({ src, description, className, ...props }) {
return (
<Paragraph>
<Anchor href={src}>
<img alt={`[${description}]`} title={description} src={src} className={classNames(Style.Image, className)} {...props}/>
</Anchor>
</Paragraph>
)
}

View file

@ -0,0 +1,3 @@
.Image {
max-width: 100%;
}