Skip to content
New issue

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

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

Already on GitHub? # to your account

Fix dropdowns being added multiple times to the same element #9835

Merged
merged 3 commits into from
Oct 7, 2024

Conversation

janfaracik
Copy link
Contributor

Somewhat subtle bug, discovered in https://github.com/jenkinsci/acceptance-test-harness/pull/1756/checks?check_run_id=31138933435. Essentially if applySubtree is called on an overflow button, it triggers another dropdown to be added to it. They overlap so it's still functional, however it is visible by the dropdown having a very dark shadow as a result.

This PR fixes that by destroying any existing dropdowns before adding another one, the same way the tooltips operate in https://github.com/jenkinsci/jenkins/blob/master/war/src/main/js/components/tooltips/index.js#17.

Testing done

  • Only one dropdown is added now
  • Existing dropdowns work as before

Proposed changelog entries

  • N/A

Proposed upgrade guidelines

N/A

Submitter checklist

Preview Give feedback

Desired reviewers

@jenkinsci/sig-ux

Before the changes are marked as ready-for-merge:

Maintainer checklist

Preview Give feedback

Copy link
Member

@timja timja left a comment

Choose a reason for hiding this comment

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

Thanks!

@timja timja added bug For changelog: Minor bug. Will be listed after features web-ui The PR includes WebUI changes which may need special expertise skip-changelog Should not be shown in the changelog and removed bug For changelog: Minor bug. Will be listed after features labels Oct 6, 2024
@timja
Copy link
Member

timja commented Oct 6, 2024

/label ready-for-merge


This PR is now ready for merge, after ~24 hours, we will merge it if there's no negative feedback.

Thanks!

@comment-ops-bot comment-ops-bot bot added the ready-for-merge The PR is ready to go, and it will be merged soon if there is no negative feedback label Oct 6, 2024
@timja timja merged commit 7dfdceb into jenkinsci:master Oct 7, 2024
16 checks passed
@timja timja deleted the fix-dropdowns branch October 7, 2024 13:53
@basil basil added the ath-fail The acceptance-test-harness suite needs a forward-compatible change label Oct 9, 2024
@basil
Copy link
Member

basil commented Oct 9, 2024

Broke ATH in jenkinsci/acceptance-test-harness#1771.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
ath-fail The acceptance-test-harness suite needs a forward-compatible change ready-for-merge The PR is ready to go, and it will be merged soon if there is no negative feedback skip-changelog Should not be shown in the changelog web-ui The PR includes WebUI changes which may need special expertise
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants