From 921a5b49414788418523cfb558a7ee0e3560b95a Mon Sep 17 00:00:00 2001 From: epriestley Date: Tue, 21 Jun 2016 15:11:04 -0700 Subject: [PATCH] Push typehead browse result selector button down one
Summary: Fixes T11190. The div with all the stuff in it was sometimes ending up on top of the "select" button, making it unclickable. Test Plan: Clicked "select" in several browsers. Reviewers: chad Reviewed By: chad Maniphest Tasks: T11190 Differential Revision: https://secure.phabricator.com/D16160 --- ...icatorTypeaheadModularDatasourceController.php | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/src/applications/typeahead/controller/PhabricatorTypeaheadModularDatasourceController.php b/src/applications/typeahead/controller/PhabricatorTypeaheadModularDatasourceController.php index fd1473aee9..a7c8381bfd 100644 --- a/src/applications/typeahead/controller/PhabricatorTypeaheadModularDatasourceController.php +++ b/src/applications/typeahead/controller/PhabricatorTypeaheadModularDatasourceController.php @@ -143,8 +143,6 @@ final class PhabricatorTypeaheadModularDatasourceController $items = array(); foreach ($results as $result) { - $information = $this->renderBrowseResult($result); - // Disable already-selected tokens. $disabled = isset($exclude[$result->getPHID()]); @@ -161,15 +159,14 @@ final class PhabricatorTypeaheadModularDatasourceController ), pht('Select')); + $information = $this->renderBrowseResult($result, $button); + $items[] = phutil_tag( 'div', array( 'class' => 'typeahead-browse-item grouped', ), - array( - $button, - $information, - )); + $information); } $markup = array( @@ -352,7 +349,10 @@ final class PhabricatorTypeaheadModularDatasourceController ->appendChild($view); } - private function renderBrowseResult(PhabricatorTypeaheadResult $result) { + private function renderBrowseResult( + PhabricatorTypeaheadResult $result, + $button) { + $class = array(); $style = array(); $separator = " \xC2\xB7 "; @@ -399,6 +399,7 @@ final class PhabricatorTypeaheadModularDatasourceController 'style' => implode(' ', $style), ), array( + $button, $name, $attributes, ));