From b88474a1a85388ac24c6c923d64aee8e27d5887e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kacper=20Miko=C5=82ajczak?= Date: Mon, 8 Jan 2024 13:50:42 +0100 Subject: [PATCH] fix TooltipProps child --- src/components/Tooltip/types.ts | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/components/Tooltip/types.ts b/src/components/Tooltip/types.ts index 739e9a4d0a22..253013f49761 100644 --- a/src/components/Tooltip/types.ts +++ b/src/components/Tooltip/types.ts @@ -1,9 +1,7 @@ -import type {ReactElement, ReactNode} from 'react'; - -type TooltipProps = { - /** The children to render the tooltip for. On web it has to be proper HTML element to attach event handlers to. */ - children: ReactElement | ReactNode; +import type {ReactNode} from 'react'; +import type ChildrenProps from '@src/types/utils/ChildrenProps'; +type TooltipProps = ChildrenProps & { /** The text to display in the tooltip. If text is ommitted, only children will be rendered. */ text?: string;