global-context/features/refresh/realtime-control/realtime-control.component.ts
| changeDetection | ChangeDetectionStrategy.OnPush |
||
| providers |
)
|
||
| selector | c8y-realtime-control |
||
| standalone | true |
||
| imports |
TooltipModule
C8yTranslatePipe
|
||
| templateVariables |
|
||
| templateUrl | ./realtime-control.component.html |
No results matching.
TooltipModule
C8yTranslatePipe
FormsModule
)
ControlValueAccessor
@let buttonLabel = (isActive ? disableRealtimeLabel : enableRealtimeLabel) | translate;
<button
class="btn btn-icon c8y-realtime"
[attr.aria-label]="buttonLabel"
[tooltip]="tooltipTpl"
placement="top"
container="body"
type="button"
data-cy="global-context--realtime-toggle"
(click)="onButtonClick()"
[adaptivePosition]="false"
[delay]="500"
[disabled]="disabled"
>
<span
class="c8y-pulse m-0"
[class.active]="isActive"
[class.inactive]="!isActive"
></span>
</button>
<ng-template #tooltipTpl>
{{ buttonLabel }}
</ng-template>