import { ReactNode } from "react";
import { Direction } from "../types";

export type FieldProps =  {
    children: ReactNode;
    direction?: Direction;
  }

export default function Field({
  children,
  direction = "vertical",
}: FieldProps) {
  return (
    <div
      className={`fl-flex ${
        direction === "vertical" ? "fl-flex-col fl-space-y-2" : "fl-flex-row fl-space-x-2"
      }`}
    >
      {children}
    </div>
  );
}
