Skip to content
Snippets Groups Projects
Commit bf779288 authored by Loïc Correnson's avatar Loïc Correnson Committed by Michele Alberti
Browse files

[ivette] fix dynamic column renderers

parent e9d6bdfb
No related branches found
No related tags found
No related merge requests found
......@@ -18,15 +18,23 @@ import { Label } from 'dome/controls/labels';
// --- Columns
// --------------------------------------------------------------------------
const CallstackRenderer = (
(cs: Eva.callstack) => <Label label={cs.short} title={cs.full} />
);
const ColumnCallstack = () => Column({
id: 'callstack',
label: 'Callstack',
title: 'Context of the evaluation',
align: 'left',
width: 100,
render: (cs: Eva.callstack) => <Label label={cs.short} title={cs.full} />,
render: CallstackRenderer
});
const AlarmRenderer = (
(alarm: boolean) => <>{alarm && <Icon id="ATTENTION" />}</>
);
const ColumnAlarm = (props: { visible: boolean }) => Column({
id: 'alarm',
label: 'Alarm',
......@@ -36,7 +44,7 @@ const ColumnAlarm = (props: { visible: boolean }) => Column({
fixed: true,
icon: 'WARNING',
visible: props.visible,
render: (alarm: boolean) => <>{alarm && <Icon id="ATTENTION" />}</>,
render: AlarmRenderer
});
// --------------------------------------------------------------------------
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment