'use client'; import React from 'react'; import { FlyoutBackdrop, FlyoutDialog } from './components/index.js'; import { type FlyoutProps } from './flyout.types.js'; export function Flyout({ backdropClassName, children, className, closeAssistiveText, heading, headingTag, isDismissable = true, isKeyboardDismissDisabled, portalContainer, position = 'right', shouldCloseOnInteractOutside, state, zIndex, ...props }: FlyoutProps) { return ( {({ flyoutRef, modalProps }) => ( state.close() : undefined} position={position} key={position} > {children} )} ); }