Skip to content

Commit 859146f

Browse files
authored
fix(Dropdown): handle text as a content in renderLabel (#4047)
1 parent c3640e4 commit 859146f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/modules/Dropdown/Dropdown.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,9 @@ const getKeyAndValues = (options) =>
4141
function renderItemContent(item) {
4242
const { flag, image, text } = item
4343

44-
// TODO: remove this in v2
44+
// TODO: remove this in v3
4545
// This maintains compatibility with Shorthand API in v1 as this might be called in "Label.create()"
46-
if (React.isValidElement(text) || _.isFunction(text)) {
46+
if (_.isFunction(text)) {
4747
return text
4848
}
4949

0 commit comments

Comments
 (0)