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

Implements

AfterViewInit OnDestroy ControlValueAccessor

Metadata

Relationships

@let showIntervalRefresh = showIntervalRefresh$ | async;
@let autoRefreshSeconds = autoRefreshSeconds$ | async;
@let isBtnDisabled = isBtnDisabled$ | async;
@let tooltipText = (showIntervalRefresh ? DISABLE_AUTO_REFRESH : ENABLE_AUTO_REFRESH) | translate;

<button
  class="toggle-countdown"
  [attr.aria-label]="tooltipText"
  [tooltip]="tooltipText"
  placement="top"
  container="body"
  (click)="toggleIntervalRefresh()"
  [adaptivePosition]="false"
  mode
  [delay]="500"
  [disabled]="isBtnDisabled"
>
  @if (showIntervalRefresh) {
    <c8y-countdown-interval
      [countdownInterval]="autoRefreshSeconds ?? DEFAULT_INTERVAL_VALUE"
    ></c8y-countdown-interval>
  } @else {
    <i c8yIcon="pause"></i>
  }
</button>

results matching ""

    No results matching ""