Tobias Brunner
301e297d45
All checks were successful
continuous-integration/drone/push Build is passing
36 lines
682 B
Plaintext
36 lines
682 B
Plaintext
{
|
|
/**
|
|
* @name row.new
|
|
*/
|
|
new(
|
|
title='Dashboard Row',
|
|
height=null,
|
|
collapse=false,
|
|
repeat=null,
|
|
showTitle=null,
|
|
titleSize='h6'
|
|
):: {
|
|
collapse: collapse,
|
|
collapsed: collapse,
|
|
[if height != null then 'height']: height,
|
|
panels: [],
|
|
repeat: repeat,
|
|
repeatIteration: null,
|
|
repeatRowId: null,
|
|
showTitle:
|
|
if showTitle != null then
|
|
showTitle
|
|
else
|
|
title != 'Dashboard Row',
|
|
title: title,
|
|
type: 'row',
|
|
titleSize: titleSize,
|
|
addPanels(panels):: self {
|
|
panels+: panels,
|
|
},
|
|
addPanel(panel, gridPos={}):: self {
|
|
panels+: [panel { gridPos: gridPos }],
|
|
},
|
|
},
|
|
}
|