mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-22 23:02:42 +01:00
Show a snippet when hovering inlines in the objective list
Summary: Ref T12733. Shows a comment snippet when hovering inlines in the objective list. Test Plan: {F4968490} Reviewers: chad Reviewed By: chad Maniphest Tasks: T12733 Differential Revision: https://secure.phabricator.com/D17980
This commit is contained in:
parent
7a40dd380e
commit
4dff754502
3 changed files with 14 additions and 11 deletions
|
@ -13,7 +13,7 @@ return array(
|
|||
'core.pkg.js' => '599698a7',
|
||||
'darkconsole.pkg.js' => '1f9a31bc',
|
||||
'differential.pkg.css' => '7d4cfa59',
|
||||
'differential.pkg.js' => 'd7e3edd5',
|
||||
'differential.pkg.js' => '06cddcc0',
|
||||
'diffusion.pkg.css' => 'b93d9b8c',
|
||||
'diffusion.pkg.js' => '84c8f8fd',
|
||||
'favicon.ico' => '30672e08',
|
||||
|
@ -392,7 +392,7 @@ return array(
|
|||
'rsrc/js/application/dashboard/behavior-dashboard-tab-panel.js' => 'd4eecc63',
|
||||
'rsrc/js/application/diff/DiffChangeset.js' => 'cf4e2140',
|
||||
'rsrc/js/application/diff/DiffChangesetList.js' => 'a716ca27',
|
||||
'rsrc/js/application/diff/DiffInline.js' => 'ca0fafde',
|
||||
'rsrc/js/application/diff/DiffInline.js' => '4478f8ac',
|
||||
'rsrc/js/application/diff/ScrollObjective.js' => '9df4e4e2',
|
||||
'rsrc/js/application/diff/ScrollObjectiveList.js' => '085dd101',
|
||||
'rsrc/js/application/diff/behavior-preview-link.js' => '051c7832',
|
||||
|
@ -779,7 +779,7 @@ return array(
|
|||
'phabricator-dashboard-css' => 'fe5b1869',
|
||||
'phabricator-diff-changeset' => 'cf4e2140',
|
||||
'phabricator-diff-changeset-list' => 'a716ca27',
|
||||
'phabricator-diff-inline' => 'ca0fafde',
|
||||
'phabricator-diff-inline' => '4478f8ac',
|
||||
'phabricator-drag-and-drop-file-upload' => '58dea2fa',
|
||||
'phabricator-draggable-list' => 'bea6e7f4',
|
||||
'phabricator-fatal-config-template-css' => '8f18fa41',
|
||||
|
@ -1203,6 +1203,9 @@ return array(
|
|||
'javelin-workflow',
|
||||
'javelin-workboard-controller',
|
||||
),
|
||||
'4478f8ac' => array(
|
||||
'javelin-dom',
|
||||
),
|
||||
'44959b73' => array(
|
||||
'javelin-util',
|
||||
'javelin-uri',
|
||||
|
@ -1976,9 +1979,6 @@ return array(
|
|||
'phabricator-shaped-request',
|
||||
'conpherence-thread-manager',
|
||||
),
|
||||
'ca0fafde' => array(
|
||||
'javelin-dom',
|
||||
),
|
||||
'caade6f2' => array(
|
||||
'javelin-behavior',
|
||||
'javelin-request',
|
||||
|
|
|
@ -421,6 +421,11 @@ final class PHUIDiffInlineCommentDetailView
|
|||
$actions,
|
||||
));
|
||||
|
||||
$snippet = id(new PhutilUTF8StringTruncator())
|
||||
->setMaximumGlyphs(96)
|
||||
->truncateString($inline->getContent());
|
||||
$metadata['snippet'] = pht('%s: %s', $author, $snippet);
|
||||
|
||||
$markup = javelin_tag(
|
||||
'div',
|
||||
array(
|
||||
|
@ -444,10 +449,6 @@ final class PHUIDiffInlineCommentDetailView
|
|||
phutil_tag_div('phabricator-remarkup', $content)),
|
||||
));
|
||||
|
||||
$snippet = id(new PhutilUTF8StringTruncator())
|
||||
->setMaximumGlyphs(96)
|
||||
->truncateString($inline->getContent());
|
||||
|
||||
$summary = phutil_tag(
|
||||
'div',
|
||||
array(
|
||||
|
|
|
@ -22,6 +22,7 @@ JX.install('DiffInline', {
|
|||
_undoRow: null,
|
||||
_replyToCommentPHID: null,
|
||||
_originalText: null,
|
||||
_snippet: null,
|
||||
|
||||
_isDeleted: false,
|
||||
_isInvisible: false,
|
||||
|
@ -75,6 +76,7 @@ JX.install('DiffInline', {
|
|||
|
||||
this._changesetID = data.changesetID;
|
||||
this._isNew = false;
|
||||
this._snippet = data.snippet;
|
||||
|
||||
this.setInvisible(false);
|
||||
|
||||
|
@ -219,7 +221,7 @@ JX.install('DiffInline', {
|
|||
|
||||
var icon = 'fa-comment';
|
||||
var color = 'bluegrey';
|
||||
var tooltip = null;
|
||||
var tooltip = this._snippet;
|
||||
var anchor = this._row;
|
||||
|
||||
if (this._isEditing) {
|
||||
|
|
Loading…
Reference in a new issue