File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
static/app/views/preprod/main Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -220,6 +220,10 @@ export function AppSizeTreemap(props: AppSizeTreemapProps) {
220
220
formatter : function ( params : any ) {
221
221
const value = typeof params . value === 'number' ? params . value : 0 ;
222
222
const percent = ( ( value / totalSize ) * 100 ) . toFixed ( 2 ) ;
223
+ const pathElement = params . data ?. path
224
+ ? `<p style="font-size: 12px; margin-bottom: -4px;">${ params . data . path } </p>`
225
+ : null ;
226
+
223
227
return `
224
228
<div style="font-family: Rubik;">
225
229
<div style="display: flex; align-items: center; font-size: 12px; font-weight: bold; line-height: 1; margin-bottom: ${ space ( 1 ) } ; gap: ${ space ( 1 ) } ">
@@ -228,11 +232,11 @@ export function AppSizeTreemap(props: AppSizeTreemapProps) {
228
232
</div>
229
233
<div style="display: flex; flex-direction: column; line-height: 1; gap: ${ space ( 0.5 ) } ">
230
234
<p style="font-size: 14px; font-weight: bold; margin-bottom: -2px;">${ params . name } </p>
231
- <p style="font-size: 12px; margin-bottom: -4px;"> ${ params . data ?. path } </p>
235
+ ${ pathElement || '' }
232
236
<p style="font-size: 12px; margin-bottom: -4px;">${ formatBytesBase10 ( value ) } (${ percent } %)</p>
233
237
</div>
234
238
</div>
235
- ` ;
239
+ ` . trim ( ) ;
236
240
} ,
237
241
} ;
238
242
You can’t perform that action at this time.
0 commit comments