Skip to content

Commit 1e47ba2

Browse files
author
Chad Little
committed
Use setDrag UI for reordering workboard columns
Summary: This UI can use the setDrag call to reduce clutter on the reodering dialog. Test Plan: Reorder some columns, save. {F4959906} Reviewers: epriestley Reviewed By: epriestley Subscribers: Korvin Differential Revision: https://secure.phabricator.com/D17898
1 parent 2fb1edf commit 1e47ba2

File tree

3 files changed

+16
-12
lines changed

3 files changed

+16
-12
lines changed

resources/celerity/map.php

+6-6
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
'names' => array(
1010
'conpherence.pkg.css' => 'ff161f2d',
1111
'conpherence.pkg.js' => 'b5b51108',
12-
'core.pkg.css' => 'd1bf3405',
12+
'core.pkg.css' => 'ee5f28cd',
1313
'core.pkg.js' => '2ff7879f',
1414
'darkconsole.pkg.js' => '1f9a31bc',
1515
'differential.pkg.css' => '58712637',
@@ -129,7 +129,7 @@
129129
'rsrc/css/phui/calendar/phui-calendar.css' => '477acfaa',
130130
'rsrc/css/phui/object-item/phui-oi-big-ui.css' => '19f9369b',
131131
'rsrc/css/phui/object-item/phui-oi-color.css' => 'cd2b9b77',
132-
'rsrc/css/phui/object-item/phui-oi-drag-ui.css' => 'f12cbc9f',
132+
'rsrc/css/phui/object-item/phui-oi-drag-ui.css' => '08f4ccc3',
133133
'rsrc/css/phui/object-item/phui-oi-flush-ui.css' => '9d9685d6',
134134
'rsrc/css/phui/object-item/phui-oi-list-view.css' => '7c8ec27a',
135135
'rsrc/css/phui/object-item/phui-oi-simple-ui.css' => 'a8beebea',
@@ -873,7 +873,7 @@
873873
'phui-object-box-css' => '9cff003c',
874874
'phui-oi-big-ui-css' => '19f9369b',
875875
'phui-oi-color-css' => 'cd2b9b77',
876-
'phui-oi-drag-ui-css' => 'f12cbc9f',
876+
'phui-oi-drag-ui-css' => '08f4ccc3',
877877
'phui-oi-flush-ui-css' => '9d9685d6',
878878
'phui-oi-list-view-css' => '7c8ec27a',
879879
'phui-oi-simple-ui-css' => 'a8beebea',
@@ -977,6 +977,9 @@
977977
'javelin-stratcom',
978978
'javelin-vector',
979979
),
980+
'08f4ccc3' => array(
981+
'phui-oi-list-view-css',
982+
),
980983
'0a0b10e9' => array(
981984
'javelin-behavior',
982985
'javelin-stratcom',
@@ -2170,9 +2173,6 @@
21702173
'f10fd7a3' => array(
21712174
'javelin-install',
21722175
),
2173-
'f12cbc9f' => array(
2174-
'phui-oi-list-view-css',
2175-
),
21762176
'f50152ad' => array(
21772177
'phui-timeline-view-css',
21782178
),

src/applications/project/controller/PhabricatorProjectBoardReorderController.php

+2-6
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,8 @@ public function handleRequest(AphrontRequest $request) {
9494
$list = id(new PHUIObjectItemListView())
9595
->setUser($viewer)
9696
->setID($list_id)
97-
->setFlush(true);
97+
->setFlush(true)
98+
->setDrag(true);
9899

99100
foreach ($columns as $column) {
100101
// Don't allow milestone columns to be reordered.
@@ -134,14 +135,9 @@ public function handleRequest(AphrontRequest $request) {
134135
'reorderURI' => $reorder_uri,
135136
));
136137

137-
$note = id(new PHUIInfoView())
138-
->appendChild(pht('Drag and drop columns to reorder them.'))
139-
->setSeverity(PHUIInfoView::SEVERITY_NOTICE);
140-
141138
return $this->newDialog()
142139
->setTitle(pht('Reorder Columns'))
143140
->setWidth(AphrontDialogView::WIDTH_FORM)
144-
->appendChild($note)
145141
->appendChild($list)
146142
->addSubmitButton(pht('Done'));
147143
}

webroot/rsrc/css/phui/object-item/phui-oi-drag-ui.css

+8
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,10 @@
2323
margin-top: 4px;
2424
}
2525

26+
.phui-oi-drag .phui-oi-name {
27+
padding-left: 0;
28+
}
29+
2630
.phui-oi-drag.phui-oi-with-image-icon .phui-oi-frame,
2731
.phui-oi-drag.phui-oi-with-image .phui-oi-frame,
2832
.phui-oi-drag .phui-oi-frame {
@@ -57,3 +61,7 @@
5761
.phui-oi-list-drag .drag-ghost {
5862
margin-top: 4px;
5963
}
64+
65+
.phui-oi-list-drag .phui-object-icon-pane {
66+
padding-right: 8px;
67+
}

0 commit comments

Comments
 (0)