mirror of
https://github.com/grafana/grafana.git
synced 2025-08-01 21:02:16 +08:00
Add errorIconColor prop to TraceSpanData (#26509)
This commit is contained in:
@ -59,6 +59,7 @@ export type TraceSpanData = {
|
|||||||
warnings?: string[] | null;
|
warnings?: string[] | null;
|
||||||
stackTraces?: string[];
|
stackTraces?: string[];
|
||||||
flags: number;
|
flags: number;
|
||||||
|
errorIconColor?: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
export type TraceSpan = TraceSpanData & {
|
export type TraceSpan = TraceSpanData & {
|
||||||
|
@ -252,7 +252,6 @@ const getStyles = createStyle((theme: Theme) => {
|
|||||||
`,
|
`,
|
||||||
errorIcon: css`
|
errorIcon: css`
|
||||||
label: errorIcon;
|
label: errorIcon;
|
||||||
background: ${autoColor(theme, '#db2828')};
|
|
||||||
border-radius: 6.5px;
|
border-radius: 6.5px;
|
||||||
color: ${autoColor(theme, '#fff')};
|
color: ${autoColor(theme, '#fff')};
|
||||||
font-size: 0.85em;
|
font-size: 0.85em;
|
||||||
@ -418,7 +417,16 @@ export class UnthemedSpanBarRow extends React.PureComponent<SpanBarRowProps> {
|
|||||||
[styles.svcNameChildrenCollapsed]: isParent && !isChildrenExpanded,
|
[styles.svcNameChildrenCollapsed]: isParent && !isChildrenExpanded,
|
||||||
})}
|
})}
|
||||||
>
|
>
|
||||||
{showErrorIcon && <IoAlert className={styles.errorIcon} />}
|
{showErrorIcon && (
|
||||||
|
<IoAlert
|
||||||
|
style={{
|
||||||
|
backgroundColor: span.errorIconColor
|
||||||
|
? autoColor(theme, span.errorIconColor)
|
||||||
|
: autoColor(theme, '#db2828'),
|
||||||
|
}}
|
||||||
|
className={styles.errorIcon}
|
||||||
|
/>
|
||||||
|
)}
|
||||||
{serviceName}{' '}
|
{serviceName}{' '}
|
||||||
{rpc && (
|
{rpc && (
|
||||||
<span>
|
<span>
|
||||||
|
Reference in New Issue
Block a user