@neoprototype/neop-ui-lib 1.1.2 → 1.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { Injectable, NgModule, Input, ViewChild, Component, EventEmitter, Output, InjectionToken, Optional, Inject, ElementRef, HostListener, ViewChildren, TemplateRef } from '@angular/core';
|
|
2
|
+
import { Injectable, NgModule, Input, ViewChild, Component, EventEmitter, Output, InjectionToken, Optional, Inject, ElementRef, HostListener, ViewChildren, inject, PLATFORM_ID, afterNextRender, TemplateRef } from '@angular/core';
|
|
3
3
|
import * as i1 from 'ng-zorro-antd/modal';
|
|
4
4
|
import { NzModalModule } from 'ng-zorro-antd/modal';
|
|
5
5
|
import { Subject, debounceTime } from 'rxjs';
|
|
@@ -2547,6 +2547,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.5", ngImpor
|
|
|
2547
2547
|
class NpTabComponent {
|
|
2548
2548
|
_Router;
|
|
2549
2549
|
_ActivatedRoute;
|
|
2550
|
+
platformId = inject(PLATFORM_ID);
|
|
2550
2551
|
headerWrapperRef;
|
|
2551
2552
|
scrollContainerRef;
|
|
2552
2553
|
tabItemRefs;
|
|
@@ -2565,6 +2566,16 @@ class NpTabComponent {
|
|
|
2565
2566
|
constructor(_Router, _ActivatedRoute) {
|
|
2566
2567
|
this._Router = _Router;
|
|
2567
2568
|
this._ActivatedRoute = _ActivatedRoute;
|
|
2569
|
+
afterNextRender(() => {
|
|
2570
|
+
this.initBrowserLogic();
|
|
2571
|
+
});
|
|
2572
|
+
}
|
|
2573
|
+
initBrowserLogic() {
|
|
2574
|
+
const wrapper = this.headerWrapperRef?.nativeElement;
|
|
2575
|
+
if (wrapper) {
|
|
2576
|
+
wrapper.addEventListener('scroll', this.updateScrollButtons);
|
|
2577
|
+
}
|
|
2578
|
+
this.updateScrollButtons();
|
|
2568
2579
|
}
|
|
2569
2580
|
ngOnInit() {
|
|
2570
2581
|
this.setTabActiveDefault();
|