Added fwt components

This commit is contained in:
Patrick Alvin Alcala 2025-09-04 12:05:03 +08:00
parent b7409d1c13
commit b2cbd947c5
30 changed files with 852 additions and 0 deletions

View file

@ -0,0 +1,20 @@
import type { ImageMetadata } from 'astro'
import './Box.sass'
import { Show, type JSXElement, createMemo } from 'solid-js'
interface Props {
thickness: number
color?: string
children: JSXElement
curved?: boolean
}
export default (props: Props) => {
const boxClass = createMemo(() => (props.curved ? 'curvedbox' : 'box'))
return (
<section class={boxClass()} style={{ border: `${props.thickness}px solid ${props.color || 'white'}` }}>
{props.children}
</section>
)
}