diff --git a/projects/demo/src/modules/app/pages.ts b/projects/demo/src/modules/app/pages.ts index f1be32eeb930..2e0e6788a057 100644 --- a/projects/demo/src/modules/app/pages.ts +++ b/projects/demo/src/modules/app/pages.ts @@ -927,12 +927,6 @@ export const pages: TuiDocPages = [ keywords: 'tabs, control, radio, navigation, навигация, вкладки, таб', route: '/experimental/segmented', }, - { - section: 'Experimental', - title: 'Sensitive', - keywords: 'sensitive, pixel, mask, пиксель, маска', - route: '/experimental/sensitive', - }, { section: 'Experimental', title: 'Surface', @@ -1381,6 +1375,12 @@ export const pages: TuiDocPages = [ keywords: 'overflow, ellipsis, gradient, clamp, line', route: '/directives/fade', }, + { + section: 'Tools', + title: 'Sensitive', + keywords: 'sensitive, pixel, mask, пиксель, маска', + route: '/directives/sensitive', + }, ], }, { diff --git a/projects/experimental/components/swipe-action/swipe-actions-auto-close.directive.ts b/projects/experimental/components/swipe-action/swipe-actions-auto-close.directive.ts deleted file mode 100644 index 241d23df29ca..000000000000 --- a/projects/experimental/components/swipe-action/swipe-actions-auto-close.directive.ts +++ /dev/null @@ -1,31 +0,0 @@ -import {Directive, ElementRef, inject, Input} from '@angular/core'; -import {tuiGetActualTarget} from '@taiga-ui/cdk'; - -@Directive({ - selector: 'tui-swipe-actions[autoClose]', - host: { - '(document:pointerdown.silent)': 'handleEvent($event)', - '(document:focusin.silent)': 'handleEvent($event)', - }, -}) -export class TuiSwipeActionsAutoCloseDirective { - private readonly el: HTMLElement = inject(ElementRef).nativeElement; - - @Input() - public autoClose: boolean | string = true; - - protected handleEvent(event: Event): void { - const target = tuiGetActualTarget(event); - - if (this.autoClose !== false && !this.el.contains(target)) { - this.close(); - } - } - - private close(): void { - this.el.scrollTo({ - left: 0, - behavior: 'smooth', - }); - } -}