Skip to content

Commit

Permalink
refactor: add tuiZonefreeScheduler to TuiInputFilesDirective (#8883)
Browse files Browse the repository at this point in the history
  • Loading branch information
splincode authored Sep 23, 2024
1 parent 9f570c6 commit a07ff9f
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import {Directive, forwardRef, inject, Output} from '@angular/core';
import {tuiAsControl, TuiControl} from '@taiga-ui/cdk/classes';
import {EMPTY_ARRAY} from '@taiga-ui/cdk/constants';
import {TuiNativeValidator} from '@taiga-ui/cdk/directives/native-validator';
import {tuiControlValue} from '@taiga-ui/cdk/observables';
import {tuiControlValue, tuiZonefreeScheduler} from '@taiga-ui/cdk/observables';
import {tuiInjectElement} from '@taiga-ui/cdk/utils/dom';
import type {TuiAppearanceOptions} from '@taiga-ui/core/directives/appearance';
import {
Expand Down Expand Up @@ -46,7 +46,7 @@ export class TuiInputFilesDirective
protected readonly host = inject(forwardRef(() => TuiInputFiles));

@Output()
public readonly reject = timer(0).pipe(
public readonly reject = timer(0, tuiZonefreeScheduler()).pipe(
switchMap(() => tuiControlValue(this.control.control)),
map(() => tuiFilesRejected(this.control.control)),
filter(({length}) => !!length),
Expand Down

0 comments on commit a07ff9f

Please sign in to comment.