|
1 | 1 | import type { ChangeEvent } from "react"; |
2 | | -import { useMemo, useState, Fragment } from "react"; |
| 2 | +import { Fragment, useMemo, useState } from "react"; |
| 3 | +import { styled } from "styled-components"; |
3 | 4 | import type { |
4 | 5 | SetPerformanceComparisonQueries, |
5 | 6 | ToComparePerformanceViewMessage, |
6 | 7 | } from "../../common/interface-types"; |
7 | | -import { useMessageFromExtension } from "../common/useMessageFromExtension"; |
| 8 | +import { formatDecimal } from "../../common/number"; |
8 | 9 | import type { |
9 | 10 | PerformanceComparisonDataFromLog, |
10 | 11 | PipelineSummary, |
11 | 12 | } from "../../log-insights/performance-comparison"; |
12 | | -import { formatDecimal } from "../../common/number"; |
13 | | -import { styled } from "styled-components"; |
14 | | -import { Codicon, ViewTitle, WarningBox } from "../common"; |
| 13 | +import { |
| 14 | + Codicon, |
| 15 | + ComparePerformanceDescription, |
| 16 | + InfoBox, |
| 17 | + ViewTitle, |
| 18 | + WarningBox, |
| 19 | +} from "../common"; |
| 20 | +import { useMessageFromExtension } from "../common/useMessageFromExtension"; |
15 | 21 | import { abbreviateRANames, abbreviateRASteps } from "./RAPrettyPrinter"; |
16 | 22 |
|
17 | 23 | const enum AbsentReason { |
@@ -443,6 +449,11 @@ function ComparePerformanceWithData(props: { |
443 | 449 | return ( |
444 | 450 | <> |
445 | 451 | <ViewTitle>Performance comparison</ViewTitle> |
| 452 | + {data?.description && ( |
| 453 | + <InfoBox> |
| 454 | + <ComparePerformanceDescription {...data.description} /> |
| 455 | + </InfoBox> |
| 456 | + )} |
446 | 457 | {hasCacheHitMismatch && ( |
447 | 458 | <WarningBox> |
448 | 459 | <strong>Inconsistent cache hits</strong> |
|
0 commit comments