mirror of
https://github.com/grafana/grafana.git
synced 2026-07-30 00:08:10 -05:00
Table: Fix no data message alignment and table selector name (#77700)
* on multiple queries show no data message aligned + set a default table name for empty series * simplify style * check if there are fields
This commit is contained in:
@@ -31,7 +31,7 @@ export function getFrameDisplayName(frame: DataFrame, index?: number) {
|
||||
}
|
||||
|
||||
// list all the
|
||||
if (index === undefined) {
|
||||
if (index === undefined && frame.fields.length > 0) {
|
||||
return frame.fields
|
||||
.filter((f) => f.type !== FieldType.time)
|
||||
.map((f) => getFieldDisplayName(f, frame))
|
||||
|
||||
@@ -372,7 +372,7 @@ export const Table = memo((props: Props) => {
|
||||
</CustomScrollbar>
|
||||
</div>
|
||||
) : (
|
||||
<div style={{ height: height - headerHeight }} className={tableStyles.noData}>
|
||||
<div style={{ height: height - headerHeight, width }} className={tableStyles.noData}>
|
||||
No data
|
||||
</div>
|
||||
)}
|
||||
|
||||
Reference in New Issue
Block a user