//#region src/lib/slot.d.ts /** * Minimal replacement for `@radix-ui/react-slot`. * * Renders its single child element with the parent's props * (className, style, event handlers, ref, data-* attributes) * merged onto it. Used by the sidebar shell for the `asChild` * pattern. * * Ref composition logic adapted from the MIT-licensed * `@radix-ui/react-compose-refs` (v1.1.2). * * This module intentionally uses `Children.only` and * `cloneElement`: it is a low-level composition primitive * that merges props onto a single child, which is exactly * the use case React documents for these APIs. * * Several lint suppressions are necessary because prop * merging is inherently dynamic; the types of child props * are not statically known. */ type SlotProps = React.HTMLAttributes & { children?: React.ReactNode; ref?: React.Ref | undefined; }; declare const Slot: ({ ref: parentRef, children, className, style, ...rest }: SlotProps) => React.ReactNode; //#endregion export { Slot };