import * as React from "react"; import { formFieldStack } from "../style"; import { Card } from "../../card"; import { Icon } from "../../icon"; import { ResetButton } from "../../button"; import { SystemIcons } from "../../icons/dist/system-icons-enum"; import { Flex, FlexItem } from "../../styleUtils/layout"; interface FormSubSectionProps { onRemove?: (event?: React.SyntheticEvent) => void; children?: React.ReactNode; /** * Allows custom styling */ className?: string; /** * Human-readable selector used for writing tests */ "data-cy"?: string; } const FormSubSection = ({ children, className, "data-cy": dataCy = "formSubSection", onRemove }: FormSubSectionProps) => { const subSectionContent =
{children}
; return ( {onRemove ? ( {subSectionContent} ) : ( subSectionContent )} ); }; export default FormSubSection;