Skip to content
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

LabeledSelect: Show tag prompts only if select is searchable #13073

Merged
merged 1 commit into from
Jan 16, 2025

Conversation

houhoucoop
Copy link
Contributor

@houhoucoop houhoucoop commented Jan 13, 2025

Summary

Fixes #6946

when there were no options, the prompt text start typing to delete an item would appear even if the select was not searchable.

Occurred changes and/or fixed issues

  • Modified the logic to ensure the prompt only shows if the select is searchable

Technical notes summary

The showTagPrompts was introduced in PR#12350
Ref: https://github.com/rancher/dashboard/pull/12350/files#diff-5316c4da698262a356a5f70f02f4d94b95c66b780cedf9cb04515deb011017d8R148-R151

Areas or cases that should be tested

Verify the prompt text only appears when:

  • There are no options available and select is both taggable and searchable

Areas which could experience regressions

Prompt display behavior in LabeledSelect component when there are no options

Screenshot/Video

Show No options if the select was not searchable
Screenshot 2025-01-13 at 2 50 25 PM (2)

Checklist

  • The PR is linked to an issue and the linked issue has a Milestone, or no issue is needed
  • The PR has a Milestone
  • The PR template has been filled out
  • The PR has been self reviewed
  • The PR has a reviewer assigned
  • The PR has automated tests or clear instructions for manual tests and the linked issue has appropriate QA labels, or tests are not needed
  • The PR has reviewed with UX and tested in light and dark mode, or there are no UX changes

Copy link
Member

@torchiaf torchiaf left a comment

Choose a reason for hiding this comment

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

LGTM since the new prop was introduced in 2.10.1 I don't expect that the new condition would break anything in Rancher

@houhoucoop houhoucoop merged commit 36d8a06 into rancher:master Jan 16, 2025
45 of 51 checks passed
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.

[ENHANCEMENT][GUI] cluster output select dropdown should show meaningful sentence if no options available
2 participants