@taiga-ui/kit
Version:
Taiga UI Angular main components kit
16 lines (14 loc) • 22.2 kB
JavaScript
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("@angular/core"),require("@angular/router"),require("@taiga-ui/cdk"),require("@taiga-ui/core"),require("@taiga-ui/kit/tokens"),require("rxjs"),require("@angular/common"),require("rxjs/operators"),require("@tinkoff/ng-polymorpheus"),require("@ng-web-apis/mutation-observer"),require("@ng-web-apis/common"),require("@tinkoff/ng-event-plugins")):"function"==typeof define&&define.amd?define("@taiga-ui/kit/components/tabs",["exports","@angular/core","@angular/router","@taiga-ui/cdk","@taiga-ui/core","@taiga-ui/kit/tokens","rxjs","@angular/common","rxjs/operators","@tinkoff/ng-polymorpheus","@ng-web-apis/mutation-observer","@ng-web-apis/common","@tinkoff/ng-event-plugins"],t):t(((e=e||self)["taiga-ui"]=e["taiga-ui"]||{},e["taiga-ui"].kit=e["taiga-ui"].kit||{},e["taiga-ui"].kit.components=e["taiga-ui"].kit.components||{},e["taiga-ui"].kit.components.tabs={}),e.ng.core,e.ng.router,e.cdk,e.core$1,e["taiga-ui"].kit.tokens,e.rxjs,e.ng.common,e.rxjs.operators,e.ngPolymorpheus,e.mutationObserver,e.common$1,e.ngEventPlugins)}(this,(function(e,t,n,i,o,r,a,s,c,u,p,l,d){"use strict";
/*! *****************************************************************************
Copyright (c) Microsoft Corporation.
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
PERFORMANCE OF THIS SOFTWARE.
***************************************************************************** */function h(e,t,n,i){var o,r=arguments.length,a=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,n,a):o(t,n))||a);return r>3&&a&&Object.defineProperty(t,n,a),a}function f(e,t){return function(n,i){t(n,i,e)}}var g=function(){function e(e){this.template=e}return e.ctorParameters=function(){return[{type:t.TemplateRef,decorators:[{type:t.Inject,args:[t.TemplateRef]}]}]},e=h([t.Directive({selector:"ng-template[tuiTab]"}),f(0,t.Inject(t.TemplateRef))],e)}(),m=new t.InjectionToken("Stream of tab activation events"),v=[i.TuiDestroyService,i.TuiFocusVisibleService,o.TuiRouterLinkActiveService,{provide:m,deps:[t.ElementRef,s.DOCUMENT,o.TuiRouterLinkActiveService],useFactory:I},o.MODE_PROVIDER];function I(e,t,n){var o=e.nativeElement;return a.merge(n.pipe(c.filter(i.identity)),o.matches("button")?i.typedFromEvent(o,"click"):a.EMPTY).pipe(c.map((function(){return o.dispatchEvent(i.tuiCustomEvent("tui-tab-activate",{bubbles:!0},t))})))}var b=function(){function e(e,t,n,i,o,r,a){var s=this;this.routerLinkActive=e,this.mode$=t,this.event$=n,this.focusVisible=!1,this.isIos=i&&o,this.isAndroid=i&&r,a.subscribe((function(e){s.focusVisible=e}))}return Object.defineProperty(e.prototype,"isActive",{get:function(){return!!this.routerLinkActive&&this.routerLinkActive.isActive},enumerable:!0,configurable:!0}),e.ctorParameters=function(){return[{type:n.RouterLinkActive,decorators:[{type:t.Optional},{type:t.Inject,args:[n.RouterLinkActive]}]},{type:a.Observable,decorators:[{type:t.Inject,args:[o.TUI_MODE]}]},{type:a.Observable,decorators:[{type:t.Inject,args:[m]}]},{type:Boolean,decorators:[{type:t.Inject,args:[r.TUI_MOBILE_AWARE]}]},{type:Boolean,decorators:[{type:t.Inject,args:[i.TUI_IS_IOS]}]},{type:Boolean,decorators:[{type:t.Inject,args:[i.TUI_IS_ANDROID]}]},{type:i.TuiFocusVisibleService,decorators:[{type:t.Inject,args:[i.TuiFocusVisibleService]}]}]},h([t.HostBinding("class._ios")],e.prototype,"isIos",void 0),h([t.HostBinding("class._android")],e.prototype,"isAndroid",void 0),h([t.HostBinding("class._focus-visible")],e.prototype,"focusVisible",void 0),h([t.HostBinding("class._active")],e.prototype,"isActive",null),e=h([t.Component({selector:"a[tuiTab]:not([routerLink]), a[tuiTab][routerLink][routerLinkActive], button[tuiTab]",template:'<ng-container *ngIf="event$ | async"></ng-container>\n<span class="highlight"><ng-content></ng-content></span>\n',changeDetection:t.ChangeDetectionStrategy.OnPush,providers:v,host:{"($.data-mode.attr)":"mode$"},styles:[":host-context(._underline):hover{box-shadow:inset 0 -2px var(--tui-base-03)}:host{transition-duration:.3s;transition-timing-function:ease-in-out;-webkit-appearance:none;-moz-appearance:none;appearance:none;padding:0;border:0;background:0 0;font-size:inherit;line-height:inherit;position:relative;display:flex;flex-shrink:0;height:100%;justify-content:space-between;align-items:center;white-space:nowrap;cursor:pointer;outline:0;text-decoration:none;color:inherit;transition-property:color,box-shadow,opacity}:host:not(:last-child){margin-right:24px}:host:hover{color:var(--tui-text-01)}:host:disabled{opacity:var(--tui-disabled-opacity);pointer-events:none}:host:not([data-mode])._active{opacity:1;color:var(--tui-text-01);box-shadow:none}:host[data-mode=onDark]{color:rgba(255,255,255,.72)}:host[data-mode=onDark]._active,:host[data-mode=onDark]:hover{color:#fff}:host[data-mode=onDark]._focus-visible .highlight{background:var(--tui-clear-inverse);color:var(--tui-text-01)}:host[data-mode=onLight]{color:rgba(0,0,0,.56)}:host[data-mode=onLight]._focus-visible .highlight{background:var(--tui-text-01);color:#fff}:host._focus-visible .highlight{background:var(--tui-selection)}:host._android{transition-property:opacity;transition-duration:.3s;transition-timing-function:ease-in-out;height:48px;flex:1;flex-shrink:0;justify-content:center;margin:0;text-transform:uppercase;color:var(--tui-base-09);opacity:.5;font-size:14px;font-weight:500;letter-spacing:-.13px;font-family:-apple-system,BlinkMacSystemFont,Roboto,'Helvetica Neue',sans-serif}:host._android:hover{box-shadow:none}:host._android._active{opacity:1;color:var(--tui-base-09)}:host._android .highlight{width:auto}:host._ios{height:28px;flex:1;flex-shrink:0;justify-content:center;margin:0;color:var(--tui-base-01);opacity:1;font-size:13px;font-weight:500;letter-spacing:-.08px;font-family:-apple-system,BlinkMacSystemFont,Roboto,'Helvetica Neue',sans-serif}:host._ios:hover{box-shadow:none}:host._ios._active{font-size:14px;font-weight:600;color:var(--tui-link)}:host._ios .highlight{width:auto}.highlight{display:inline-flex;width:100%;align-items:center;justify-content:inherit}.highlight ::ng-deep>*{flex-shrink:0}"]}),f(0,t.Optional()),f(0,t.Inject(n.RouterLinkActive)),f(1,t.Inject(o.TUI_MODE)),f(2,t.Inject(m)),f(3,t.Inject(r.TUI_MOBILE_AWARE)),f(4,t.Inject(i.TUI_IS_IOS)),f(5,t.Inject(i.TUI_IS_ANDROID)),f(6,t.Inject(i.TuiFocusVisibleService))],e)}(),y=function(){function e(e,n,o,r,a,s,u){var p=this;this.elementRef=e,this.renderer=n,this.underline=!0,this.activeItemIndexChange=new t.EventEmitter,this.children=i.EMPTY_QUERY,this.activeItemIndex=0,this.isIos=u&&a,this.isAndroid=u&&s,r.pipe(c.filter((function(){return p.underline}))).subscribe((function(){o.detectChanges()}))}return Object.defineProperty(e.prototype,"activeItemIndexSetter",{set:function(e){this.activeItemIndex=e,this.scrollTo(this.tabs[e])},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"refresh$",{get:function(){return i.itemsQueryListObservable(this.children).pipe(c.mapTo(!0))},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"tabs",{get:function(){return Array.from(this.elementRef.nativeElement.querySelectorAll("[tuiTab]"))},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"activeElement",{get:function(){return this.tabs[this.activeItemIndex]||null},enumerable:!0,configurable:!0}),e.prototype.ngAfterViewChecked=function(){var e=this,t=this.tabs,n=this.activeElement;t.forEach((function(t){e.renderer.removeClass(t,"_active"),e.renderer.setAttribute(t,"tabIndex","-1")})),n&&(this.renderer.addClass(n,"_active"),this.renderer.setAttribute(n,"tabIndex","0"))},e.prototype.onActivate=function(e){var t=this.tabs.findIndex((function(t){return t===e}));t!==this.activeItemIndex&&(this.activeItemIndexSetter=t,this.activeItemIndexChange.emit(t))},e.prototype.onKeyDownArrow=function(e,t){var n=this.tabs;i.moveFocus(n.indexOf(e),n,t)},e.prototype.scrollTo=function(e){if(e){var t=e.offsetLeft,n=e.offsetWidth,i=this.elementRef.nativeElement;t<i.scrollLeft&&(i.scrollLeft=t),t+n>i.scrollLeft+i.offsetWidth&&(i.scrollLeft=t+n-i.offsetWidth)}},e.ctorParameters=function(){return[{type:t.ElementRef,decorators:[{type:t.Inject,args:[t.ElementRef]}]},{type:t.Renderer2,decorators:[{type:t.Inject,args:[t.Renderer2]}]},{type:t.ChangeDetectorRef,decorators:[{type:t.Inject,args:[t.ChangeDetectorRef]}]},{type:a.Observable,decorators:[{type:t.Inject,args:[i.TuiResizeService]}]},{type:Boolean,decorators:[{type:t.Inject,args:[i.TUI_IS_IOS]}]},{type:Boolean,decorators:[{type:t.Inject,args:[i.TUI_IS_ANDROID]}]},{type:Boolean,decorators:[{type:t.Inject,args:[r.TUI_MOBILE_AWARE]}]}]},h([t.Input(),t.HostBinding("class._underline"),i.tuiDefaultProp()],e.prototype,"underline",void 0),h([t.Input("activeItemIndex")],e.prototype,"activeItemIndexSetter",null),h([t.Output()],e.prototype,"activeItemIndexChange",void 0),h([t.HostBinding("class._ios")],e.prototype,"isIos",void 0),h([t.HostBinding("class._android")],e.prototype,"isAndroid",void 0),h([t.ContentChildren(t.forwardRef((function(){return b})))],e.prototype,"children",void 0),h([i.tuiPure],e.prototype,"refresh$",null),h([t.HostListener("tui-tab-activate.stop",["$event.target"])],e.prototype,"onActivate",null),h([t.HostListener("keydown.arrowRight.prevent",["$event.target","1"]),t.HostListener("keydown.arrowLeft.prevent",["$event.target","-1"])],e.prototype,"onKeyDownArrow",null),e=h([t.Component({selector:"tui-tabs, nav[tuiTabs]",template:'<tui-underline\n *ngIf="underline && (refresh$ | async)"\n [element]="activeElement"\n></tui-underline>\n<ng-content></ng-content>\n',changeDetection:t.ChangeDetectionStrategy.OnPush,host:{class:"tui-zero-scrollbar"},providers:[i.TuiDestroyService,i.TuiResizeService],styles:[":host{font:var(--tui-font-text-m);position:relative;display:flex;height:var(--tui-height-l);color:var(--tui-text-02);box-shadow:inset 0 -1px var(--tui-base-03);overflow:auto}:host._android{height:auto}:host._ios{height:auto;border:2px solid transparent;border-radius:9px;background:var(--tui-link);box-shadow:none}"]}),f(0,t.Inject(t.ElementRef)),f(1,t.Inject(t.Renderer2)),f(2,t.Inject(t.ChangeDetectorRef)),f(3,t.Inject(i.TuiResizeService)),f(4,t.Inject(i.TUI_IS_IOS)),f(5,t.Inject(i.TUI_IS_ANDROID)),f(6,t.Inject(r.TUI_MOBILE_AWARE))],e)}();function x(e,t,n,i,o,r){var s=i.body,u=o.nativeElement;return a.merge(e,t.pipe(c.tap((function(){return r.detectChanges()})))).pipe(c.filter((function(){return s.contains(u)})),c.debounceTime(0),c.startWith(null),c.takeUntil(n))}var _=new t.InjectionToken("Refresh stream"),T={childList:!0,subtree:!0},w=[i.TuiResizeService,i.TuiDestroyService,p.MutationObserverService,{provide:p.MUTATION_OBSERVER_INIT,useValue:T},{provide:_,deps:[i.TuiResizeService,p.MutationObserverService,i.TuiDestroyService,s.DOCUMENT,t.ElementRef,t.ChangeDetectorRef],useFactory:x}],R=function(){function e(e,n,o,r){this.refresh$=e,this.elementRef=n,this.changeDetectorRef=o,this.moreWord$=r,this.moreContent="",this.underline=!0,this.activeItemIndex=0,this.itemsLimit=1/0,this.activeItemIndexChange=new t.EventEmitter,this.items=i.EMPTY_QUERY,this.open=!1,this.maxIndex=1/0}return Object.defineProperty(e.prototype,"tabs",{get:function(){return Array.from(this.elementRef.nativeElement.querySelectorAll("[tuiTab]"))},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"activeElement",{get:function(){return this.tabs[this.activeItemIndex]||null},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"isMoreVisible",{get:function(){return this.lastVisibleIndex<this.items.length-1},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"isMoreFocusable",{get:function(){return!!this.moreButton&&i.isNativeFocused(this.moreButton.nativeElement)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"lastVisibleIndex",{get:function(){if(this.itemsLimit+1>=this.items.length)return this.maxIndex;var e=this.itemsLimit-1>this.activeItemIndex?1:2;return Math.min(this.itemsLimit-e,this.maxIndex)},enumerable:!0,configurable:!0}),e.prototype.ngAfterViewInit=function(){var e=this;this.refresh$.pipe(c.map((function(){return e.getMaxIndex()})),c.filter((function(t){return e.maxIndex!==t}))).subscribe((function(t){e.maxIndex=t,e.changeDetectorRef.detectChanges()}))},e.prototype.onActiveItemIndexChange=function(e){this.updateActiveItemIndex(e)},e.prototype.onClick=function(e){this.open=!1,this.focusMore(),this.updateActiveItemIndex(e)},e.prototype.onArrowRight=function(e){i.isNativeFocused(e)&&this.focusMore()},e.prototype.onArrowLeft=function(){for(var e=this.tabs,t=e.length-2;t>=0;){if(i.setNativeFocused(e[t]),i.isNativeFocused(e[t]))return;t--}},e.prototype.onWrapperArrow=function(e,t,n){var o=i.getClosestFocusable(e,n,t);o&&i.setNativeFocused(o)},e.prototype.focusMore=function(){this.moreButton&&i.setNativeFocused(this.moreButton.nativeElement)},e.prototype.getMaxIndex=function(){var e=this.tabs,t=this.activeItemIndex;if(e.length<2)return 0;var n=this.elementRef.nativeElement.clientWidth,i=e[t]?e[t].scrollWidth:0,o=e[e.length-1].scrollWidth,r=e.length-2,a=e.reduce((function(e,t){return e+t.scrollWidth}),0)+24*r-o;if(a<=n)return 1/0;for(;r;){if((a-=e[r].scrollWidth+24)+(t>--r?i+24:0)+o+24<n)return r}return 0},e.prototype.updateActiveItemIndex=function(e){this.activeItemIndex!==e&&(this.activeItemIndex=e,this.activeItemIndexChange.emit(e),this.maxIndex=this.getMaxIndex())},e.ctorParameters=function(){return[{type:a.Observable,decorators:[{type:t.Inject,args:[_]}]},{type:t.ElementRef,decorators:[{type:t.Inject,args:[t.ElementRef]}]},{type:t.ChangeDetectorRef,decorators:[{type:t.Inject,args:[t.ChangeDetectorRef]}]},{type:a.Observable,decorators:[{type:t.Inject,args:[r.TUI_MORE_WORD]}]}]},h([t.Input(),i.tuiDefaultProp()],e.prototype,"moreContent",void 0),h([t.Input(),t.HostBinding("class._underline"),i.tuiDefaultProp()],e.prototype,"underline",void 0),h([t.Input(),i.tuiDefaultProp()],e.prototype,"activeItemIndex",void 0),h([t.Input(),i.tuiDefaultProp()],e.prototype,"itemsLimit",void 0),h([t.Output()],e.prototype,"activeItemIndexChange",void 0),h([t.ContentChildren(g,{read:t.TemplateRef})],e.prototype,"items",void 0),h([t.ViewChild(b,{read:t.ElementRef})],e.prototype,"moreButton",void 0),e=h([t.Component({selector:"tui-tabs-with-more, nav[tuiTabsWithMore]",template:'<ng-container *ngIf="items.changes | async"></ng-container>\n<div class="wrapper">\n <tui-tabs\n class="tabs"\n [underline]="false"\n [activeItemIndex]="activeItemIndex"\n (activeItemIndexChange)="onActiveItemIndexChange($event)"\n (keydown.arrowRight)="onArrowRight($event.target)"\n >\n <ng-container *ngFor="let item of items; let index = index">\n <ng-container\n *ngIf="index <= lastVisibleIndex; else hidden"\n [ngTemplateOutlet]="item"\n ></ng-container>\n <ng-template #hidden>\n <div\n class="overflown"\n [class.overflown_hidden]="index !== activeItemIndex"\n >\n <ng-container *ngTemplateOutlet="item"></ng-container>\n </div>\n </ng-template>\n </ng-container>\n </tui-tabs>\n <tui-hosted-dropdown\n class="more_wrapper"\n [class.overflown_hidden]="!isMoreVisible"\n [content]="dropdown"\n [(open)]="open"\n >\n <button\n tuiTab\n type="button"\n class="more"\n [class._active]="open"\n [tuiFocusable]="isMoreFocusable"\n (keydown.arrowLeft.prevent)="onArrowLeft()"\n >\n <span polymorpheus-outlet [content]="moreContent || more"></span>\n </button>\n <ng-template #more>\n {{moreWord$ | async}}\n <tui-svg\n src="tuiIconChevronDown"\n class="icon"\n [class.icon_rotated]="open"\n ></tui-svg>\n </ng-template>\n </tui-hosted-dropdown>\n <ng-template #dropdown>\n <div\n #element\n class="dropdown"\n (keydown.arrowUp.prevent)="onWrapperArrow($event.target, element, true)"\n (keydown.arrowDown.prevent)="onWrapperArrow($event.target, element, false)"\n >\n <div\n *ngFor="let item of items; let index = index"\n (tui-tab-activate)="onClick(index)"\n >\n <ng-container\n *ngIf="index > lastVisibleIndex && index !== activeItemIndex"\n [ngTemplateOutlet]="item"\n ></ng-container>\n </div>\n </div>\n </ng-template>\n <tui-underline *ngIf="underline" [element]="activeElement"></tui-underline>\n</div>\n',changeDetection:t.ChangeDetectionStrategy.OnPush,providers:w,styles:[":host{font:var(--tui-font-text-m);position:relative;display:flex;height:var(--tui-height-l);box-sizing:border-box;color:var(--tui-text-02);box-shadow:inset 0 -1px var(--tui-base-03);overflow:hidden}.wrapper{position:relative;display:flex}.tabs{height:inherit;font-size:inherit;font-weight:inherit;overflow:visible;box-shadow:none;color:inherit}.overflown{margin-right:24px}.overflown_hidden{margin:0;width:0;max-width:0;overflow:hidden;visibility:hidden}.more_wrapper{height:100%}.icon{transition-property:transform;transition-duration:.3s;transition-timing-function:ease-in-out;margin-right:-4px;vertical-align:bottom}.icon_rotated{transform:rotate(180deg)}.dropdown{padding:8px 0}.dropdown ::ng-deep [tuiTab]{width:100%;height:44px;justify-content:flex-start;margin:0;padding:0 16px;color:var(--tui-text-02)}.dropdown ::ng-deep [tuiTab]:before{display:none}.dropdown ::ng-deep [tuiTab]._active,.dropdown ::ng-deep [tuiTab]:focus,.dropdown ::ng-deep [tuiTab]:hover{box-shadow:none;color:var(--tui-base-08);background:var(--tui-base-02)}"]}),f(0,t.Inject(_)),f(1,t.Inject(t.ElementRef)),f(2,t.Inject(t.ChangeDetectorRef)),f(3,t.Inject(r.TUI_MORE_WORD))],e)}(),A=function(){function e(e,t,n,o,r,s,u){var p=this,l=e.nativeElement;this.ngZone=t,this.animationFrame$=n,this.mobileAware=o,this.ios=r,this.android=s,this.mode$=u,this.isIos=this.mobileAware&&this.ios,this.isAndroid=this.mobileAware&&this.android,this.element$=new a.ReplaySubject(1),this.refresh$=this.element$.pipe(c.switchMap((function(e){return e?p.animationFrame$.pipe(c.mapTo(e),i.tuiZonefree(p.ngZone)):a.of(null)})),c.share()),this.transition$=d.asCallable(this.element$.pipe(c.map((function(e){return e&&"all"})),c.debounceTime(50))),this.transform$=d.asCallable(this.refresh$.pipe(c.map((function(e){return e?"translate3d("+i.px(e.offsetLeft)+", 0, 0)":null})))),this.width$=d.asCallable(this.refresh$.pipe(c.map((function(e){return e?e.clientWidth:0})))),l["$.style.transitionProperty"]=this.transition$,l["$.style.transform"]=this.transform$,l["$.style.width.px"]=this.width$}return Object.defineProperty(e.prototype,"element",{set:function(e){this.element$.next(e)},enumerable:!0,configurable:!0}),e.ctorParameters=function(){return[{type:t.ElementRef,decorators:[{type:t.Inject,args:[t.ElementRef]}]},{type:t.NgZone,decorators:[{type:t.Inject,args:[t.NgZone]}]},{type:a.Observable,decorators:[{type:t.Inject,args:[l.ANIMATION_FRAME]}]},{type:Boolean,decorators:[{type:t.Inject,args:[r.TUI_MOBILE_AWARE]}]},{type:Boolean,decorators:[{type:t.Inject,args:[i.TUI_IS_IOS]}]},{type:Boolean,decorators:[{type:t.Inject,args:[i.TUI_IS_ANDROID]}]},{type:a.Observable,decorators:[{type:t.Inject,args:[o.TUI_MODE]}]}]},h([t.Input(),i.tuiDefaultProp()],e.prototype,"element",null),h([t.HostBinding("class._ios")],e.prototype,"isIos",void 0),h([t.HostBinding("class._android")],e.prototype,"isAndroid",void 0),h([t.HostListener("$.style.transitionProperty")],e.prototype,"transition$",void 0),h([t.HostListener("$.style.transform")],e.prototype,"transform$",void 0),h([t.HostListener("$.style.width.px")],e.prototype,"width$",void 0),e=h([t.Component({selector:"tui-underline",template:"",changeDetection:t.ChangeDetectionStrategy.OnPush,providers:[o.MODE_PROVIDER],host:{"($.data-mode.attr)":"mode$"},styles:[":host{transition-duration:.3s;transition-timing-function:ease-in-out;position:absolute;left:0;height:100%;color:var(--tui-primary);transform:scale(0);box-shadow:inset 0 -3px 0 -1px;transition-property:none;pointer-events:none}:host._ios{border-radius:7px;background:var(--tui-base-01);box-shadow:0 3px 1px rgba(0,0,0,.04),0 3px 8px rgba(0,0,0,.12)}:host._android{box-shadow:inset 0 -3px var(--tui-link)}:host[data-mode=onDark]{color:var(--tui-text-01-night)}:host[data-mode=onLight]{color:#666}"]}),f(0,t.Inject(t.ElementRef)),f(1,t.Inject(t.NgZone)),f(2,t.Inject(l.ANIMATION_FRAME)),f(3,t.Inject(r.TUI_MOBILE_AWARE)),f(4,t.Inject(i.TUI_IS_IOS)),f(5,t.Inject(i.TUI_IS_ANDROID)),f(6,t.Inject(o.TUI_MODE))],e)}(),j=function(){function e(){}return e=h([t.NgModule({imports:[s.CommonModule,o.TuiHostedDropdownModule,o.TuiSvgModule,i.TuiFocusableModule,u.PolymorpheusModule],declarations:[R,y,b,A,g],exports:[R,y,b,g]})],e)}();e.TABS_PROVIDERS=w,e.TABS_REFRESH=_,e.TAB_ACTIVE_CLASS="_active",e.TAB_MARGIN=24,e.TUI_TAB_ACTIVATE="tui-tab-activate",e.TUI_TAB_EVENT=m,e.TUI_TAB_PROVIDERS=v,e.TuiTabComponent=b,e.TuiTabDirective=g,e.TuiTabsComponent=y,e.TuiTabsModule=j,e.TuiTabsWithMoreComponent=R,e.TuiUnderlineComponent=A,e.tabActiveFactory=I,e.tabsRefreshFactory=x,e.ɵ0=T,Object.defineProperty(e,"__esModule",{value:!0})}));
//# sourceMappingURL=taiga-ui-kit-components-tabs.umd.min.js.map