Skip to content

Conversation

tlabaj
Copy link
Contributor

@tlabaj tlabaj commented Oct 9, 2023

What: Closes #9540

@tlabaj tlabaj changed the title Searchinput feat(Search input): Added a prop to display utilities Oct 9, 2023
@patternfly-build
Copy link
Contributor

patternfly-build commented Oct 9, 2023

appendTo?: HTMLElement | (() => HTMLElement) | 'inline';
/** An accessible label for the search input. */
'aria-label'?: string;
/** Flag to indicate utilities should be displayed */
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We could update this to something along the lines of:

Suggested change
/** Flag to indicate utilities should be displayed */
/** Flag to indicate utilities should always be displayed. By default if this prop is undefined or false, utilities will only be displayed when the search input has a value. */

As is it may seem like this prop could control the rendering of utilities in general, even if other props like results are passed in. Not sure if a different prop name would also help, but can't really think of a short one (areUtilitiesAlwaysDisplayed feels like a bit much, alwaysDisplayUtilities goes against what we typically do with these sort of props)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmmm I don't know if I like the "always part". The consumer still has control and the will display it when the want. It does not technically have to be "always".

@tlabaj tlabaj requested a review from thatblindgeye October 10, 2023 18:03
@kmcfaul kmcfaul merged commit 107c7a6 into patternfly:main Oct 17, 2023
@patternfly-build
Copy link
Contributor

Your changes have been released in:

Thanks for your contribution! 🎉

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

Successfully merging this pull request may close these issues.

Enable TextInputGroupUtilities in SearchInput even with no value

4 participants