Skip to content

Dropdown text is limited to string but should accept React.Node and Dropdown.Text is not available in TypeScript. #4518

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
GeoDaz opened this issue Mar 21, 2025 · 0 comments

Comments

@GeoDaz
Copy link

GeoDaz commented Mar 21, 2025

Bug Report

DropdownProps.text?: string. It should accept React.Node

So to avoid it, I tried to use Dropdown.Text, but in Typescript it is not exported.
It is only in the JavaScript implementation (Dropdown.js).

declare const Dropdown: ForwardRefComponent<DropdownProps, HTMLDivElement> & {
  Divider: typeof DropdownDivider
  Header: typeof DropdownHeader
  Item: typeof DropdownItem
  Menu: typeof DropdownMenu
  SearchInput: typeof DropdownSearchInput
}
@GeoDaz GeoDaz changed the title Dropdown text is limited to text but should accept React.Node and Dropdown.Text is not available in TypeScript. Dropdown text is limited to string but should accept React.Node and Dropdown.Text is not available in TypeScript. Mar 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant