diff --git a/projects/addon-mobile/components/pull-to-refresh/pull-to-refresh.service.ts b/projects/addon-mobile/components/pull-to-refresh/pull-to-refresh.service.ts index 92cf48fb4add..3620ae7b8a4a 100644 --- a/projects/addon-mobile/components/pull-to-refresh/pull-to-refresh.service.ts +++ b/projects/addon-mobile/components/pull-to-refresh/pull-to-refresh.service.ts @@ -1,9 +1,15 @@ import type {ElementRef} from '@angular/core'; import {inject, Injectable} from '@angular/core'; -import {tuiScrollFrom, tuiTypedFromEvent} from '@taiga-ui/cdk/observables'; +import { + tuiScrollFrom, + tuiTypedFromEvent, + tuiZonefreeScheduler, + tuiZoneOptimized, +} from '@taiga-ui/cdk/observables'; import {tuiInjectElement} from '@taiga-ui/cdk/utils/dom'; import {TUI_SCROLL_REF} from '@taiga-ui/core/tokens'; import { + debounceTime, distinctUntilChanged, EMPTY, endWith, @@ -78,7 +84,9 @@ export class TuiPullToRefreshService extends Observable { startWith(0), ), ), + debounceTime(0, tuiZonefreeScheduler()), distinctUntilChanged(), + tuiZoneOptimized(), share(), );