mirror of
https://github.com/misode/misode.github.io.git
synced 2026-05-03 06:02:54 +00:00
Improve homepage (#245)
* Improve how generators are listed on home * Add some icons for generators * Remove debug * Refactor cachedFetch and use generated changelogs * Add limit to how many changes are shown by default * Add more generator icons * Refactor cards * Fix generator icons for light theme * Add more worldgen icons * Add remaining generator icons * Refactor navigation and badges style * Group on homepage for guides and tools * Fix header button style * Add versions and technical changelog to homepage * Make it clear that not all changes could be documented
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
import type { ComponentChildren } from 'preact'
|
||||
|
||||
interface Props {
|
||||
title?: ComponentChildren,
|
||||
link?: string,
|
||||
overlay?: ComponentChildren,
|
||||
children?: ComponentChildren,
|
||||
}
|
||||
export function Card({ title, overlay, link, children }: Props) {
|
||||
const content = <>
|
||||
{overlay && <span class="card-overlay">{overlay}</span>}
|
||||
<div class="card-content">
|
||||
{title && <h3 class="card-title">{title}</h3>}
|
||||
{children}
|
||||
</div>
|
||||
</>
|
||||
|
||||
return link === undefined
|
||||
? <div class="card">{content}</div>
|
||||
: <a class="card" href={link} >{content}</a>
|
||||
}
|
||||
Reference in New Issue
Block a user