Skip to content
Snippets Groups Projects

Fixed enter key in search input not working

Merged Phil Hughes requested to merge gl-dropdown-enter into master
2 unresolved threads

What does this MR do?

Fixes a bug where the enter key wouldn't search in the top nav search input

Closes #20627 (closed)

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
613 618
614 619 GitLabDropdown.prototype.selectRowAtIndex = function(index) {
615 620 var $el, selector;
616 selector = SELECTABLE_CLASSES + ":eq(" + index + ") a";
621 // If we pass an option index
622 if (index !== undefined) {
  • 623 selector = SELECTABLE_CLASSES + ":eq(" + index + ") a";
    624 } else {
    625 selector = ".dropdown-content .is-focused";
    626 }
    617 627 if (this.dropdown.find(".dropdown-toggle-page").length) {
    618 628 selector = ".dropdown-page-one " + selector;
    619 629 }
    620 630 $el = $(selector, this.dropdown);
    621 631 if ($el.length) {
    622 $el.first().trigger('click');
    623 632 var href = $el.attr('href');
    624 if (href && href !== '#') Turbolinks.visit(href);
    633 if (href && href !== '#') {
    634 Turbolinks.visit(href);
    635 } else {
    636 $el.first().trigger('click');
  • Added 46 commits:

  • Jacob Schatz Enabled an automatic merge when the build for 86f03e17 succeeds

    Enabled an automatic merge when the build for 86f03e17 succeeds

  • Jacob Schatz Status changed to merged

    Status changed to merged

  • Jacob Schatz mentioned in commit 9b079219

    mentioned in commit 9b079219

  • Should this have a CHANGELOG entry?

  • @smcgivern good call, I'm going to add it

  • Picked into 8-11-stable, will go into 8.11.1.

  • Rubén Dávila Removed ~149423 label

    Removed ~149423 label

  • Jacob Schatz mentioned in commit e6f5653c

    mentioned in commit e6f5653c

  • mentioned in issue #21180 (closed)

  • mentioned in issue #21409 (closed)

  • Please register or sign in to reply
    Loading