mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-18 12:52:42 +01:00
Conpherence - smooth out user interaction switching threads in the durable column
Summary: Ref T7014. This changes the title and selected icon right as the user clicks it. This could //maybe// be in the "willLoadThread" callback hook, but it doesn't happen every time we load a thread, just **this** time so keep it right in the listener for now. Test Plan: switched some threads and liked what I saw Reviewers: epriestley, chad Subscribers: Korvin, epriestley Maniphest Tasks: T7014 Differential Revision: https://secure.phabricator.com/D12043
This commit is contained in:
parent
194a183ea6
commit
d9adedd9d6
3 changed files with 25 additions and 11 deletions
|
@ -353,7 +353,7 @@ return array(
|
|||
'rsrc/js/application/auth/behavior-persona-login.js' => '9414ff18',
|
||||
'rsrc/js/application/config/behavior-reorder-fields.js' => '14a827de',
|
||||
'rsrc/js/application/conpherence/ConpherenceThreadManager.js' => '0324970d',
|
||||
'rsrc/js/application/conpherence/behavior-durable-column.js' => '8908d403',
|
||||
'rsrc/js/application/conpherence/behavior-durable-column.js' => '44100dc7',
|
||||
'rsrc/js/application/conpherence/behavior-menu.js' => 'c4151295',
|
||||
'rsrc/js/application/conpherence/behavior-pontificate.js' => '21ba5861',
|
||||
'rsrc/js/application/conpherence/behavior-quicksand-blacklist.js' => '7927a7d3',
|
||||
|
@ -585,7 +585,7 @@ return array(
|
|||
'javelin-behavior-diffusion-locate-file' => '6d3e1947',
|
||||
'javelin-behavior-diffusion-pull-lastmodified' => '2b228192',
|
||||
'javelin-behavior-doorkeeper-tag' => 'e5822781',
|
||||
'javelin-behavior-durable-column' => '8908d403',
|
||||
'javelin-behavior-durable-column' => '44100dc7',
|
||||
'javelin-behavior-error-log' => '6882e80a',
|
||||
'javelin-behavior-fancy-datepicker' => 'c51ae228',
|
||||
'javelin-behavior-global-drag-and-drop' => '07f199d8',
|
||||
|
@ -1110,6 +1110,15 @@ return array(
|
|||
'javelin-dom',
|
||||
'javelin-request',
|
||||
),
|
||||
'44100dc7' => array(
|
||||
'javelin-behavior',
|
||||
'javelin-dom',
|
||||
'javelin-stratcom',
|
||||
'javelin-scrollbar',
|
||||
'javelin-quicksand',
|
||||
'phabricator-keyboard-shortcut',
|
||||
'conpherence-thread-manager',
|
||||
),
|
||||
'44168bad' => array(
|
||||
'javelin-behavior',
|
||||
'javelin-dom',
|
||||
|
@ -1505,15 +1514,6 @@ return array(
|
|||
'javelin-dom',
|
||||
'javelin-vector',
|
||||
),
|
||||
'8908d403' => array(
|
||||
'javelin-behavior',
|
||||
'javelin-dom',
|
||||
'javelin-stratcom',
|
||||
'javelin-scrollbar',
|
||||
'javelin-quicksand',
|
||||
'phabricator-keyboard-shortcut',
|
||||
'conpherence-thread-manager',
|
||||
),
|
||||
'8a41885b' => array(
|
||||
'javelin-install',
|
||||
'javelin-dom',
|
||||
|
|
|
@ -186,6 +186,7 @@ final class ConpherenceDurableColumnView extends AphrontTagView {
|
|||
'sigil' => 'conpherence-durable-column-thread-icon',
|
||||
'meta' => array(
|
||||
'threadID' => $conpherence->getID(),
|
||||
'threadTitle' => $data['js_title'],
|
||||
),
|
||||
),
|
||||
phutil_tag(
|
||||
|
|
|
@ -164,7 +164,20 @@ JX.behavior('durable-column', function(config, statics) {
|
|||
'conpherence-durable-column-thread-icon',
|
||||
function (e) {
|
||||
e.kill();
|
||||
var icons = JX.DOM.scry(
|
||||
JX.$('conpherence-durable-column'),
|
||||
'a',
|
||||
'conpherence-durable-column-thread-icon');
|
||||
var data = e.getNodeData('conpherence-durable-column-thread-icon');
|
||||
var cdata = null;
|
||||
for (var i = 0; i < icons.length; i++) {
|
||||
cdata = JX.Stratcom.getData(icons[i]);
|
||||
JX.DOM.alterClass(
|
||||
icons[i],
|
||||
'selected',
|
||||
cdata.threadID == data.threadID);
|
||||
}
|
||||
JX.DOM.setContent(_getColumnTitleNode(), data.threadTitle);
|
||||
threadManager.loadThreadByID(data.threadID);
|
||||
});
|
||||
|
||||
|
|
Loading…
Reference in a new issue