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

Revamp build history search bar #5692

Merged
merged 20 commits into from
Sep 27, 2021
Merged

Revamp build history search bar #5692

merged 20 commits into from
Sep 27, 2021

Conversation

janfaracik
Copy link
Contributor

@janfaracik janfaracik commented Aug 25, 2021

Proposed changelog entries

  • Modernise the "Build History" search bar

Video

Screen.Recording.2021-08-25.at.20.58.33.mov

Submitter checklist

  • (If applicable) Jira issue is well described
  • Changelog entries and upgrade guidelines are appropriate for the audience affected by the change (users or developer, depending on the change). Examples
    • Fill-in the Proposed changelog entries section only if there are breaking changes or other changes which may require extra steps from users during the upgrade
  • Appropriate autotests or explanation to why this change has no tests
  • For dependency updates: links to external changelogs and, if possible, full diffs

Maintainer checklist

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

  • There are at least 2 approvals for the pull request and no outstanding requests for change
  • Conversations in the pull request are over OR it is explicit that a reviewer does not block the change
  • Changelog entries in the PR title and/or Proposed changelog entries are correct
  • Proper changelog labels are set so that the changelog can be generated automatically
  • If the change needs additional upgrade steps from users, upgrade-guide-needed label is set and there is a Proposed upgrade guidelines section in the PR title. (example)
  • If it would make sense to backport the change to LTS, a Jira issue must exist, be a Bug or Improvement, and be labeled as lts-candidate to be considered (see query).

@oleg-nenashev oleg-nenashev added the web-ui The PR includes WebUI changes which may need special expertise label Aug 26, 2021
@oleg-nenashev oleg-nenashev added the rfe For changelog: Minor enhancement. use `major-rfe` for changes to be highlighted label Aug 26, 2021
@oleg-nenashev oleg-nenashev self-requested a review August 26, 2021 09:57
Copy link
Contributor

@Wadeck Wadeck left a comment

Choose a reason for hiding this comment

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

Not manually tested but looks really nice :)

@@ -2292,7 +2291,7 @@ function updateBuildHistory(ajaxUrl,nBuild) {
}

function loadPage(params, focusOnSearch) {
var searchString = pageSearchInput.value;
const searchString = pageSearchInput.value;
Copy link
Contributor

Choose a reason for hiding this comment

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

Cannot use const on the hudson-behavior.js file as it's not processed through webpack. These should be vars

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done.

war/src/main/webapp/scripts/hudson-behavior.js Outdated Show resolved Hide resolved
@fqueiruga
Copy link
Contributor

Looks good. I do have some comments about some issues that will arise.

I'd also suggest using, if possible, the .setting-input CSS class to the input to provide the basic styles, and only add the needed styles on top. That way it will be updated if forms input ever get revamped.

@oleg-nenashev
Copy link
Member

@janfaracik Looks like this one is almost ready to go. WDYT about the comments by @fqueiruga ?

@janfaracik
Copy link
Contributor Author

@janfaracik Looks like this one is almost ready to go. WDYT about the comments by @fqueiruga ?

They sound sensible to me 👍 I'll be making some changes, I'll post another comment when it should be good for another look over.

@janfaracik janfaracik changed the title Revamp build history search bar draft: Revamp build history search bar Sep 17, 2021
@janfaracik
Copy link
Contributor Author

I've updated the PR based on the reviews - thanks everybody by the way :)

I've added debounce so server calls are limited, there's a short delay after typing before calling the API so it shouldn't swamp the API. I've also added a small animation to indicate that it's loading and I've also a small notice when there are no builds.

Build.history.mov

Reviews are welcome, I've extracted the JS into its own file now which makes things cleaner and easier to maintain - the file could definitely be cleaner though so would be great for people to try out the PR/suggest improvements.

Cheers

@janfaracik janfaracik changed the title draft: Revamp build history search bar Revamp build history search bar Sep 19, 2021
@timja
Copy link
Member

timja commented Sep 19, 2021

Wow I just tried out the old behaviour and that is not a nice UX, never used this before tbh

@timja
Copy link
Member

timja commented Sep 19, 2021

Icon appears to be mis-aligned for me?

Running chrome on mac big sur

image

@timja
Copy link
Member

timja commented Sep 19, 2021

Spacing appears to be off for me too, it doesn't appear like in the video above.

The x button doesn't change the cursor to show it's clickable.

doesn't look the best in dark theme but looks like there's variables there that can be used to tweak that

@janfaracik
Copy link
Contributor Author

Spacing appears to be off for me too, it doesn't appear like in the video above.

The x button doesn't change the cursor to show it's clickable.

doesn't look the best in dark theme but looks like there's variables there that can be used to tweak that

Darn Safari handles padding/line height differently for search inputs :doh: Should be all fixed now :)

The clear button also now changes the cursor on hover.

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.

the focus appears to be quite strong (and different from the rest of the application). Not that I like the focus state in the rest of the application.

I think in this case it looks fine, although if it was rolled out more widely it would probably be too 'much' when there's a number of inputs together, but I could be wrong.

My previous feedback was addressed and this is a lot better than the previous search bar

@timja timja requested a review from a team September 20, 2021 08:28
@res0nance res0nance added the squash-merge-me Unclean or useless commit history, should be merged only with squash-merge label Sep 20, 2021
@timja
Copy link
Member

timja commented Sep 26, 2021

conflicts

@timja timja added the unresolved-merge-conflict There is a merge conflict with the target branch. label Sep 26, 2021
@timja timja removed the unresolved-merge-conflict There is a merge conflict with the target branch. label Sep 27, 2021
@timja
Copy link
Member

timja commented Sep 27, 2021

@fqueiruga any chance you could take another look?

Copy link
Contributor

@fqueiruga fqueiruga left a comment

Choose a reason for hiding this comment

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

I think this is a great PR. I'm still a bit concious about the use of px but that's not a blocker.

Cheers @janfaracik , this is really nice.

@timja timja added the ready-for-merge The PR is ready to go, and it will be merged soon if there is no negative feedback label Sep 27, 2021
@timja
Copy link
Member

timja commented Sep 27, 2021

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

Thanks!

@timja timja merged commit 2116595 into jenkinsci:master Sep 27, 2021
@dheerajodha
Copy link

Suggested Edit:

  • Modernise the Build History search bar.

@timja
Copy link
Member

timja commented Sep 29, 2021

Possibly caused https://issues.jenkins.io/browse/JENKINS-66753

@janfaracik
Copy link
Contributor Author

janfaracik commented Sep 29, 2021

Possibly caused https://issues.jenkins.io/browse/JENKINS-66753

Investigating this now...

Update: Fix up for review now - #5760

@janfaracik janfaracik deleted the search-bar branch January 5, 2022 15:07
@timja timja mentioned this pull request Sep 6, 2022
13 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready-for-merge The PR is ready to go, and it will be merged soon if there is no negative feedback rfe For changelog: Minor enhancement. use `major-rfe` for changes to be highlighted squash-merge-me Unclean or useless commit history, should be merged only with squash-merge web-ui The PR includes WebUI changes which may need special expertise
Projects
None yet
7 participants