diff --git a/playbook/app/pb_kits/playbook/pb_dropdown/_dropdown.tsx b/playbook/app/pb_kits/playbook/pb_dropdown/_dropdown.tsx index 13af9cb3c5..b946f7f295 100644 --- a/playbook/app/pb_kits/playbook/pb_dropdown/_dropdown.tsx +++ b/playbook/app/pb_kits/playbook/pb_dropdown/_dropdown.tsx @@ -47,7 +47,7 @@ interface DropdownComponent Container: typeof DropdownContainer; } -const Dropdown = forwardRef((props: DropdownProps, ref: any) => { +let Dropdown = (props: DropdownProps, ref: any): React.ReactElement | null => { const { aria = {}, autocomplete = false, @@ -260,7 +260,7 @@ const Dropdown = forwardRef((props: DropdownProps, ref: any) => { {optionsWithBlankSelection && optionsWithBlankSelection?.map((option: GenericObject) => ( - ))} @@ -278,11 +278,12 @@ const Dropdown = forwardRef((props: DropdownProps, ref: any) => { ) -}) as DropdownComponent +} -Dropdown.displayName = "Dropdown"; -Dropdown.Option = DropdownOption; -Dropdown.Trigger = DropdownTrigger; -Dropdown.Container = DropdownContainer; +Dropdown = forwardRef(Dropdown) as unknown as DropdownComponent; +(Dropdown as DropdownComponent).displayName = "Dropdown"; +(Dropdown as DropdownComponent).Option = DropdownOption; +(Dropdown as DropdownComponent).Trigger = DropdownTrigger; +(Dropdown as DropdownComponent).Container = DropdownContainer; export default Dropdown;