"use client"; /* * Documentation: * Button Group — https://app.subframe.com/f023064a5ca0/library?component=Button+Group_e0379327-50f0-4852-9ae1-ad09b4bf01d3 */ import React from "react"; import * as SubframeUtils from "../../utils"; export interface ButtonGroupRootProps extends React.HTMLAttributes { vertical?: boolean; align?: "start" | "center" | "end" | "stretch"; children?: React.ReactNode; className?: string; } const ButtonGroupRoot = React.forwardRef( function ButtonGroupRoot( { vertical = false, align = "start", children, className, ...otherProps }: ButtonGroupRootProps, ref ) { return children ? (
*]:grow [&>*]:basis-0": align === "stretch", "justify-end": align === "end", "justify-center": align === "center", "flex-col items-start": vertical, }, className )} ref={ref} {...otherProps} > {children}
) : null; } ); export const ButtonGroup = ButtonGroupRoot;