From ea46d13ff603ebf08d0213eca1d49ea3765f5e3f Mon Sep 17 00:00:00 2001 From: Jaap-Hein Wester Date: Tue, 31 Dec 2024 11:23:31 +0100 Subject: [PATCH] forwardRef bug fixed --- packages/components-react/src/select/Select.tsx | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/packages/components-react/src/select/Select.tsx b/packages/components-react/src/select/Select.tsx index e1f906dd..43bd5344 100644 --- a/packages/components-react/src/select/Select.tsx +++ b/packages/components-react/src/select/Select.tsx @@ -6,14 +6,15 @@ import { } from '@utrecht/component-library-react/dist/css-module'; import './Select.css'; import clsx from 'clsx'; -import { forwardRef } from 'react'; +import { ForwardedRef, forwardRef } from 'react'; + export type LuxSelectProps = UtrechtSelectProps; export type LuxSelectOptionProps = UtrechtSelectOptionProps; -export const LuxSelect = forwardRef((props: LuxSelectProps) => { +export const LuxSelect = forwardRef((props: LuxSelectProps, ref: ForwardedRef) => { const { className, ...restProps } = props; - return ; + return ; }); export const LuxSelectOption = SelectOption;