initial commit
This commit is contained in:
commit
30f2b4714d
43 changed files with 3654 additions and 0 deletions
32
components/Layout.tsx
Normal file
32
components/Layout.tsx
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
/**
|
||||
* Copyright (c) 2025 xwra
|
||||
* SPDX-License-Identifier: AGPL-3.0-or-later
|
||||
*/
|
||||
|
||||
import { ComponentChildren } from "preact";
|
||||
|
||||
interface LayoutProps {
|
||||
children: ComponentChildren;
|
||||
[key: string]: any;
|
||||
}
|
||||
|
||||
export function Section({ children, class: className, ...props }: LayoutProps) {
|
||||
return (
|
||||
<div
|
||||
{...props}
|
||||
class={`section ${className || ""}`}
|
||||
>
|
||||
{children}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
export function Centered(
|
||||
{ children, class: className, ...props }: LayoutProps,
|
||||
) {
|
||||
return (
|
||||
<div class={`centered ${className || ""}`} {...props}>
|
||||
{children}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue