+ {state.status === 'loading' && (
+
Running report…
+ )}
+ {state.status === 'error' && (
+
+ )}
+ {state.status === 'ok' && state.rows.length === 0 && (
+
} title="No rows" description="The dataset returned no rows for this report's scope." />
+ )}
+ {state.rows.length > 0 && (
+
+
+
+ {columns.map((c) => | {c} | )}
+
+
+ {state.rows.map((row, i) => (
+
+ {columns.map((c) => {
+ const v = row[c];
+ const text = v == null ? '—' : typeof v === 'number' ? (Number.isInteger(v) ? String(v) : v.toLocaleString(undefined, { maximumFractionDigits: 2 })) : String(v);
+ return | {text} | ;
+ })}
+
+ ))}
+
+
+
+ )}
+
+