File

core/dashboard/widget-auto-refresh-context/widget-auto-refresh-context.component.ts

Implements

OnInit OnDestroy AfterViewInit

Metadata

Index

Properties
Methods
Inputs

Inputs

editMode$
Type : BehaviorSubject<boolean>

Methods

ngAfterViewInit
ngAfterViewInit()
Returns : void
ngOnDestroy
ngOnDestroy()
Returns : void
ngOnInit
ngOnInit()
Returns : void
onRefresh
onRefresh()
Returns : void

Properties

Readonly ACTION_BAR_GROUP_ID
Type : string
Default value : 'globalrefreshcontext'
Readonly ACTION_BAR_PRIORITY
Type : number
Default value : 5
form
Type : ReturnType<>
globalRefreshWidgetLoading
Default value : true
<c8y-action-bar-item
  [groupId]="ACTION_BAR_GROUP_ID"
  [priority]="ACTION_BAR_PRIORITY"
  [placement]="'left'"
>
  <form
    class="d-flex"
    [formGroup]="form"
  >
    <c8y-auto-refresh-control
      [hidden]="editMode$ | async"
      (loading)="globalRefreshWidgetLoading = $event"
      formControlName="autoRefresh"
    ></c8y-auto-refresh-control>

    <c8y-auto-refresh-select-control
      [hidden]="editMode$ | async"
      formControlName="autoRefreshSeconds"
    ></c8y-auto-refresh-select-control>
  </form>
  <div class="input-group-btn">
    <button
      class="btn btn-default"
      style="border-left: 0"
      [attr.aria-label]="'Refresh' | translate"
      [tooltip]="'Refresh' | translate"
      placement="bottom"
      type="button"
      *ngIf="!(editMode$ | async)"
      [adaptivePosition]="false"
      [delay]="500"
      [disabled]="globalRefreshWidgetLoading"
      (click)="onRefresh()"
    >
      <i
        c8yIcon="refresh"
        [ngClass]="{ 'icon-spin': globalRefreshWidgetLoading }"
      ></i>
    </button>
  </div>
</c8y-action-bar-item>

results matching ""

    No results matching ""