File tree Expand file tree Collapse file tree 1 file changed +12
-11
lines changed
src/views/codeAnalytics/InsightListView/ItemRender Expand file tree Collapse file tree 1 file changed +12
-11
lines changed Original file line number Diff line number Diff line change @@ -58,21 +58,22 @@ export class SpanItemHtmlRendering{
5858 percentileHtmls . push ( /*html*/ `<span>P${ item . percentile * 100 } </span>` ) ;
5959 percentileHtmls . push ( /*html*/ `<span>${ item . currentDuration . value } ${ item . currentDuration . unit } </span>` ) ;
6060 if ( item . previousDuration &&
61- item . changeTime &&
62- changeMeaningfulEnough ) {
61+ item . changeTime ) {
6362
6463 const rawDiff = Math . abs ( item . currentDuration . raw - item . previousDuration . raw ) ;
6564 changeMeaningfulEnough = rawDiff / item . previousDuration . raw > 0.1 && rawDiff > tolerationConstant ;
66-
67- let verb = item . previousDuration . raw > item . currentDuration . raw ? 'dropped.png' : 'rose.png' ;
65+ if ( changeMeaningfulEnough ) {
66+ let verb = item . previousDuration . raw > item . currentDuration . raw ? 'dropped.png' : 'rose.png' ;
6867
69- percentileHtmls . push ( /*html*/ `
70- <div class="flex-row">
71- <span class="change">
72- <img class="insight-main-image" style="align-self:center;" src="${ this . _viewUris . image ( verb ) } " width="8" height="8">
73- ${ this . getBestUnit ( item . previousDuration , item . currentDuration ) } , ${ item . changeTime . fromNow ( ) }
74- </span>
75- </div>` ) ;
68+ percentileHtmls . push ( /*html*/ `
69+ <div class="flex-row">
70+ <span class="change">
71+ <img class="insight-main-image" style="align-self:center;" src="${ this . _viewUris . image ( verb ) } " width="8" height="8">
72+ ${ this . getBestUnit ( item . previousDuration , item . currentDuration ) } , ${ item . changeTime . fromNow ( ) }
73+ </span>
74+ </div>` ) ;
75+ }
76+
7677
7778 // percentileHtmls.push(/*html*/ `<span class="change">
7879 // <img class="insight-main-image" style="align-self:center;" src="${this._viewUris.image(verb)}" width="8" height="8">
You can’t perform that action at this time.
0 commit comments