mirror of
https://github.com/Sendouc/sendou.ink.git
synced 2026-03-29 13:54:45 -05:00
26 lines
481 B
TypeScript
26 lines
481 B
TypeScript
import type * as React from "react";
|
|
import { RemoveFieldButton } from "./RemoveFieldButton";
|
|
|
|
export function FormFieldset({
|
|
title,
|
|
children,
|
|
onRemove,
|
|
}: {
|
|
title: string;
|
|
children: React.ReactNode;
|
|
onRemove: () => void;
|
|
}) {
|
|
return (
|
|
<fieldset className="w-min">
|
|
<legend>{title}</legend>
|
|
<div className="stack sm">
|
|
{children}
|
|
|
|
<div className="mt-4 stack items-center">
|
|
<RemoveFieldButton onClick={onRemove} />
|
|
</div>
|
|
</div>
|
|
</fieldset>
|
|
);
|
|
}
|