1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2025-01-18 02:31:10 +01:00

Push typehead browse result selector button down one <div>

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
This commit is contained in:
epriestley 2016-06-21 15:11:04 -07:00
parent f38730aab8
commit 921a5b4941

View file

@ -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,
));