core/dashboard/dashboard.component.ts
Displays a CSS grid which is customizable by the customer. You can set
c8y-dashboard-child
-components on it or position any element on it by
setting the grid CSS properties. On change (resize, or rearrange) the
component emits an change event.
changeDetection | ChangeDetectionStrategy.OnPush |
host | { |
selector | c8y-dashboard |
templateUrl | ./dashboard.component.html |
Properties |
Methods |
Inputs |
Outputs |
HostBindings |
HostListeners |
Accessors |
constructor(element: ElementRef, sanitizer: DomSanitizer)
|
|||||||||
Parameters :
|
columns
|
The amount of columns on that dashboard.
Default value : |
gap
|
The spacing between each children in pixel.
Default value : |
rows
|
The amount of rows to dusplay. Set to auto to auto extend the rows.
Type :
Default value : |
dashboardChange
|
An event fired if the dashboard was changed. $event Type: EventEmitter
|
attr.style |
attr.style:
|
Returns all positioning styles. Nasty workaround for that issue: https://github.com/angular/angular/issues/9343 |
window:resize |
window:resize()
|
emitChange | ||||||
emitChange(widget: DashboardChildComponent)
|
||||||
Parameters :
Returns :
void
|
getLastRow |
getLastRow()
|
Gets the last row (mainly for IE11 which doesn't support grid-auto-rows CSS property)
Returns :
void
|
ngAfterContentInit |
ngAfterContentInit()
|
Returns :
void
|
updateRectSize |
updateRectSize()
|
Updates the current rect size of the dashboard.
Returns :
void
|
children |
children:
|
Type : QueryList<DashboardChildComponent>
|
Decorators :
@ContentChildren(undefined)
|
All children in that dashboard. |
dashboardRect |
dashboardRect:
|
columnSize |
getcolumnSize()
|
The current column size. |
rowSize |
getrowSize()
|
The current row size. |