@ng-nest/ui 14.0.10 → 14.0.12
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.
- package/button/button.component.d.ts +1 -0
- package/esm2020/anchor/anchor.component.mjs +4 -3
- package/esm2020/button/button.component.mjs +12 -3
- package/esm2020/examples/examples.component.mjs +2 -2
- package/esm2020/radio/radio.component.mjs +2 -2
- package/esm2020/slider/slider.component.mjs +9 -5
- package/esm2020/slider/slider.property.mjs +7 -2
- package/esm2020/slider-select/slider-select.component.mjs +2 -2
- package/esm2020/table/table-body.component.mjs +3 -2
- package/esm2020/table/table.component.mjs +3 -3
- package/esm2020/tabs/tabs.component.mjs +6 -8
- package/fesm2015/ng-nest-ui-anchor.mjs +3 -2
- package/fesm2015/ng-nest-ui-anchor.mjs.map +1 -1
- package/fesm2015/ng-nest-ui-button.mjs +11 -2
- package/fesm2015/ng-nest-ui-button.mjs.map +1 -1
- package/fesm2015/ng-nest-ui-examples.mjs +2 -2
- package/fesm2015/ng-nest-ui-examples.mjs.map +1 -1
- package/fesm2015/ng-nest-ui-radio.mjs +2 -2
- package/fesm2015/ng-nest-ui-radio.mjs.map +1 -1
- package/fesm2015/ng-nest-ui-slider-select.mjs +2 -2
- package/fesm2015/ng-nest-ui-slider-select.mjs.map +1 -1
- package/fesm2015/ng-nest-ui-slider.mjs +14 -5
- package/fesm2015/ng-nest-ui-slider.mjs.map +1 -1
- package/fesm2015/ng-nest-ui-table.mjs +4 -3
- package/fesm2015/ng-nest-ui-table.mjs.map +1 -1
- package/fesm2015/ng-nest-ui-tabs.mjs +5 -7
- package/fesm2015/ng-nest-ui-tabs.mjs.map +1 -1
- package/fesm2020/ng-nest-ui-anchor.mjs +3 -2
- package/fesm2020/ng-nest-ui-anchor.mjs.map +1 -1
- package/fesm2020/ng-nest-ui-button.mjs +11 -2
- package/fesm2020/ng-nest-ui-button.mjs.map +1 -1
- package/fesm2020/ng-nest-ui-examples.mjs +2 -2
- package/fesm2020/ng-nest-ui-examples.mjs.map +1 -1
- package/fesm2020/ng-nest-ui-radio.mjs +2 -2
- package/fesm2020/ng-nest-ui-radio.mjs.map +1 -1
- package/fesm2020/ng-nest-ui-slider-select.mjs +2 -2
- package/fesm2020/ng-nest-ui-slider-select.mjs.map +1 -1
- package/fesm2020/ng-nest-ui-slider.mjs +14 -5
- package/fesm2020/ng-nest-ui-slider.mjs.map +1 -1
- package/fesm2020/ng-nest-ui-table.mjs +4 -3
- package/fesm2020/ng-nest-ui-table.mjs.map +1 -1
- package/fesm2020/ng-nest-ui-tabs.mjs +5 -7
- package/fesm2020/ng-nest-ui-tabs.mjs.map +1 -1
- package/package.json +1 -1
- package/slider/slider.component.d.ts +1 -1
- package/slider/slider.property.d.ts +6 -1
- package/tabs/tabs.component.d.ts +0 -1
|
@@ -3,7 +3,7 @@ import { EventEmitter, Component, Input, Output, Directive, Host, Optional, Self
|
|
|
3
3
|
import { __decorate } from 'tslib';
|
|
4
4
|
import * as i1$1 from '@ng-nest/ui/core';
|
|
5
5
|
import { XProperty, XInputNumber, XInputBoolean, XWithConfig, XIsChange, XResize, XIsEmpty, XSetData } from '@ng-nest/ui/core';
|
|
6
|
-
import { Subject, takeUntil, distinctUntilChanged, filter, startWith } from 'rxjs';
|
|
6
|
+
import { Subject, takeUntil, distinctUntilChanged, filter, startWith, delay } from 'rxjs';
|
|
7
7
|
import * as i4 from '@ng-nest/ui/slider';
|
|
8
8
|
import { XSliderProperty, XSliderComponent, XSliderModule } from '@ng-nest/ui/slider';
|
|
9
9
|
import * as i1 from '@angular/router';
|
|
@@ -277,11 +277,6 @@ class XTabsComponent extends XTabsProperty {
|
|
|
277
277
|
this._unSubject.unsubscribe();
|
|
278
278
|
(_a = this._resizeObserver) === null || _a === void 0 ? void 0 : _a.disconnect();
|
|
279
279
|
}
|
|
280
|
-
ngAfterContentInit() {
|
|
281
|
-
Promise.resolve().then(() => {
|
|
282
|
-
this.setRouter();
|
|
283
|
-
});
|
|
284
|
-
}
|
|
285
280
|
ngAfterContentChecked() {
|
|
286
281
|
if (this.tabs.length !== this.listTabs.length) {
|
|
287
282
|
this._tabsContentChange.next(`${this.tabs.length}-${this.listTabs.length}`);
|
|
@@ -289,6 +284,9 @@ class XTabsComponent extends XTabsProperty {
|
|
|
289
284
|
}
|
|
290
285
|
ngAfterViewInit() {
|
|
291
286
|
this.setSliderWidth();
|
|
287
|
+
Promise.resolve().then(() => {
|
|
288
|
+
this.setRouter();
|
|
289
|
+
});
|
|
292
290
|
}
|
|
293
291
|
setSliderWidth() {
|
|
294
292
|
if (this.slider && this.actionsRef) {
|
|
@@ -313,7 +311,7 @@ class XTabsComponent extends XTabsProperty {
|
|
|
313
311
|
return;
|
|
314
312
|
}
|
|
315
313
|
this.router.events
|
|
316
|
-
.pipe(filter((x) => x instanceof NavigationEnd), startWith(true), takeUntil(this._unSubject))
|
|
314
|
+
.pipe(filter((x) => x instanceof NavigationEnd), startWith(true), delay(0), takeUntil(this._unSubject))
|
|
317
315
|
.subscribe(() => {
|
|
318
316
|
this.updateRouterActive();
|
|
319
317
|
this.cdr.markForCheck();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ng-nest-ui-tabs.mjs","sources":["../../../../lib/ng-nest/ui/tabs/tabs.property.ts","../../../../lib/ng-nest/ui/tabs/tab-link.directive.ts","../../../../lib/ng-nest/ui/tabs/tab.component.ts","../../../../lib/ng-nest/ui/tabs/tab.component.html","../../../../lib/ng-nest/ui/tabs/tab-content.component.ts","../../../../lib/ng-nest/ui/tabs/tab-content.component.html","../../../../lib/ng-nest/ui/tabs/tabs.component.ts","../../../../lib/ng-nest/ui/tabs/tabs.component.html","../../../../lib/ng-nest/ui/tabs/tabs.module.ts","../../../../lib/ng-nest/ui/tabs/ng-nest-ui-tabs.ts"],"sourcesContent":["import {\r\n XData,\r\n XJustify,\r\n XProperty,\r\n XInputBoolean,\r\n XSize,\r\n XIdentityProperty,\r\n XTemplate,\r\n XInputNumber,\r\n XNumber,\r\n XBoolean,\r\n XWithConfig\r\n} from '@ng-nest/ui/core';\r\nimport { Input, TemplateRef, Output, EventEmitter, Component } from '@angular/core';\r\n\r\n/**\r\n * Tabs\r\n * @selector x-tabs\r\n * @decorator component\r\n */\r\nexport const XTabsPrefix = 'x-tabs';\r\nconst X_CONFIG_NAME = 'tabs';\r\n\r\n/**\r\n * Tabs Property\r\n */\r\n@Component({ template: '' })\r\nexport class XTabsProperty extends XProperty {\r\n /**\r\n * @zh_CN Data 数据\r\n * @en_US Data\r\n */\r\n @Input() data: XData<XTabsNode> = [];\r\n /**\r\n * @zh_CN 对齐方式\r\n * @en_US Alignment\r\n */\r\n @Input() justify: XJustify = 'start';\r\n /**\r\n * @zh_CN 样式\r\n * @en_US Style\r\n */\r\n @Input() type: XTabsType = 'block';\r\n /**\r\n * @zh_CN 布局方式\r\n * @en_US Layout\r\n */\r\n @Input() layout: XTabsLayout = 'top';\r\n /**\r\n * @zh_CN 激活的序号\r\n * @en_US Activation number\r\n */\r\n @Input() @XInputNumber() activatedIndex: XNumber = 0;\r\n /**\r\n * @zh_CN 动画\r\n * @en_US Animation\r\n */\r\n @Input() @XInputBoolean() animated: XBoolean = true;\r\n /**\r\n * @zh_CN 节点模板\r\n * @en_US Node template\r\n */\r\n @Input() nodeTpl!: TemplateRef<any>;\r\n /**\r\n * @zh_CN 尺寸\r\n * @en_US Size\r\n */\r\n @Input() @XWithConfig<XSize>(X_CONFIG_NAME, 'medium') size?: XSize;\r\n /**\r\n * @zh_CN 节点排列方式\r\n * @en_US Node arrangement\r\n */\r\n @Input() nodeJustify?: XJustify;\r\n /**\r\n * @zh_CN 隐藏标签栏,只有一个标签页时候默认隐藏(存在自定义操作模版的时候不会)\r\n * @en_US Hide the label bar, there is only one tab, the default hidden\r\n */\r\n @Input() @XInputBoolean() sliderHidden?: XBoolean;\r\n /**\r\n * @zh_CN 标签栏上的自定义操作模版\r\n * @en_US Custom template on the label bar\r\n */\r\n @Input() actionTpl?: TemplateRef<void>;\r\n /**\r\n * @zh_CN 标签页显示不下的时候显示展开所有的按钮,布局为 top 、bottom 的时候生效\r\n * @en_US When the node is not displayed, display all the buttons, and the arrangement is effective when the arrangement is row\r\n */\r\n @Input() @XWithConfig<XBoolean>(X_CONFIG_NAME, false) @XInputBoolean() showExpand?: XBoolean;\r\n /**\r\n * @zh_CN 展开所有弹框的最大高度\r\n * @en_US Expand the maximum height of all bomb frames\r\n */\r\n @Input() @XWithConfig<string>(X_CONFIG_NAME, '15rem') expandMaxHeight?: string;\r\n /**\r\n * @zh_CN angular 路由联动\r\n * @en_US Link angular router\r\n */\r\n @Input() @XInputBoolean() linkRouter?: XBoolean;\r\n /**\r\n * @zh_CN 以严格匹配模式确定联动的路由\r\n * @en_US Determine the linked route in strict matching mode\r\n */\r\n @Input() @XInputBoolean() linkExact?: XBoolean = true;\r\n /**\r\n * @zh_CN 标签切换变化的事件\r\n * @en_US Label switching event\r\n */\r\n @Output() indexChange = new EventEmitter<XActivatedTab>();\r\n}\r\n\r\n/**\r\n * @zh_CN Tabs 数据对象\r\n * @en_US Tabs data object\r\n */\r\nexport interface XTabsNode extends XIdentityProperty {\r\n /**\r\n * @zh_CN 禁用节点\r\n * @en_US Node disabled\r\n */\r\n disabled?: boolean;\r\n /**\r\n * @zh_CN 自定义属性\r\n * @en_US Custom properties\r\n */\r\n [property: string]: any;\r\n}\r\n\r\n/**\r\n * @zh_CN 激活的tab\r\n * @en_US Active tab\r\n */\r\nexport interface XActivatedTab {\r\n activatedIndex?: number;\r\n activatedTab?: XTabsNode;\r\n}\r\n\r\n/**\r\n * @zh_CN 样式类型\r\n * @en_US Style type\r\n */\r\nexport type XTabsType = 'block' | 'tag' | 'card';\r\n\r\n/**\r\n * @zh_CN 布局方式\r\n * @en_US Layout\r\n */\r\nexport type XTabsLayout = 'top' | 'right' | 'bottom' | 'left';\r\n\r\n/**\r\n * Tab\r\n * @selector x-tab\r\n * @decorator component\r\n */\r\nexport const XTabPrefix = 'x-tab';\r\n\r\n/**\r\n * Tab Property\r\n */\r\n@Component({ template: '' })\r\nexport class XTabProperty {\r\n /**\r\n * @zh_CN 标签名称,支持自定义模板\r\n * @en_US Label name, support custom template\r\n */\r\n @Input() label?: XTemplate;\r\n /**\r\n * @zh_CN 禁用\r\n * @en_US Disabeld\r\n */\r\n @Input() @XInputBoolean() disabled?: XBoolean;\r\n}\r\n","import { Directive, ElementRef, Host, Optional, Self, TemplateRef } from '@angular/core';\r\nimport { RouterLink, RouterLinkWithHref } from '@angular/router';\r\n\r\n@Directive({\r\n selector: 'ng-template[xTabLink]',\r\n exportAs: 'xTabLinkTemplate'\r\n})\r\nexport class XTabLinkTemplateDirective {\r\n constructor(@Host() public templateRef: TemplateRef<void>) {}\r\n}\r\n\r\n@Directive({\r\n selector: 'a[x-tab-link]',\r\n exportAs: 'xTabLink'\r\n})\r\nexport class XTabLinkDirective {\r\n constructor(\r\n public elementRef: ElementRef,\r\n @Optional() @Self() public routerLink?: RouterLink,\r\n @Optional() @Self() public routerLinkWithHref?: RouterLinkWithHref\r\n ) {}\r\n}\r\n","import { ChangeDetectionStrategy, Component, ContentChild, TemplateRef, ViewChild, ViewEncapsulation } from '@angular/core';\r\nimport { XTabPrefix, XTabProperty } from './tabs.property';\r\nimport { XConfigService } from '@ng-nest/ui/core';\r\nimport { XTabLinkDirective, XTabLinkTemplateDirective } from './tab-link.directive';\r\n\r\n@Component({\r\n selector: `${XTabPrefix}`,\r\n templateUrl: './tab.component.html',\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class XTabComponent extends XTabProperty {\r\n @ViewChild('contentTpl', { static: true }) content!: TemplateRef<void>;\r\n @ContentChild(XTabLinkTemplateDirective, { static: false }) linkTemplateDirective!: XTabLinkTemplateDirective;\r\n @ContentChild(XTabLinkDirective, { static: false }) linkDirective!: XTabLinkDirective;\r\n\r\n constructor(public configService: XConfigService) {\r\n super();\r\n }\r\n}\r\n","<ng-template #tabLinkTpl>\r\n <ng-content select=\"[x-tab-link]\"></ng-content>\r\n</ng-template>\r\n<ng-template #contentTpl>\r\n <ng-content></ng-content>\r\n</ng-template>\r\n","import {\r\n ChangeDetectionStrategy,\r\n Component,\r\n Input,\r\n TemplateRef,\r\n ViewEncapsulation,\r\n ElementRef,\r\n Renderer2\r\n} from '@angular/core';\r\nimport { XBoolean } from '@ng-nest/ui/core';\r\n\r\n@Component({\r\n selector: 'x-tab-content',\r\n preserveWhitespaces: false,\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n templateUrl: './tab-content.component.html'\r\n})\r\nexport class XTabContentComponent {\r\n @Input() content!: TemplateRef<void>;\r\n @Input() active: XBoolean = false;\r\n constructor(private elementRef: ElementRef, private renderer: Renderer2) {\r\n this.renderer.addClass(this.elementRef.nativeElement, 'x-tab-content');\r\n }\r\n}\r\n","<ng-container>\r\n <ng-template [ngTemplateOutlet]=\"content\"></ng-template>\r\n</ng-container>\r\n","import {\r\n Component,\r\n OnInit,\r\n ChangeDetectionStrategy,\r\n OnChanges,\r\n SimpleChanges,\r\n ChangeDetectorRef,\r\n ContentChildren,\r\n ViewChild,\r\n ViewEncapsulation,\r\n SimpleChange,\r\n QueryList,\r\n ElementRef,\r\n Renderer2,\r\n Optional\r\n} from '@angular/core';\r\nimport { XTabsPrefix, XTabsNode, XTabsProperty } from './tabs.property';\r\nimport { XIsChange, XSetData, XIsEmpty, XConfigService, XResize } from '@ng-nest/ui/core';\r\nimport { Subject, takeUntil, distinctUntilChanged, filter, startWith } from 'rxjs';\r\nimport { XSliderComponent, XSliderProperty } from '@ng-nest/ui/slider';\r\nimport { XTabComponent } from './tab.component';\r\nimport { NavigationEnd, Router, RouterLink, RouterLinkWithHref } from '@angular/router';\r\n\r\n@Component({\r\n selector: `${XTabsPrefix}`,\r\n templateUrl: './tabs.component.html',\r\n styleUrls: ['./style/index.scss'],\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class XTabsComponent extends XTabsProperty implements OnInit, OnChanges {\r\n sliderOption = new XSliderProperty();\r\n tabs: XTabsNode[] = [];\r\n private _unSubject = new Subject<void>();\r\n private _tabsContentChange = new Subject<string>();\r\n private _resizeObserver!: ResizeObserver;\r\n\r\n get activeIndex() {\r\n return Number(this.activatedIndex);\r\n }\r\n\r\n @ContentChildren(XTabComponent) listTabs!: QueryList<XTabComponent>;\r\n\r\n @ViewChild(XSliderComponent, { static: false }) slider!: XSliderComponent;\r\n @ViewChild('actionsRef', { static: false }) actionsRef!: ElementRef;\r\n\r\n constructor(\r\n private cdr: ChangeDetectorRef,\r\n public configService: XConfigService,\r\n public renderer: Renderer2,\r\n @Optional() private router: Router\r\n ) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.setClassMap();\r\n this.setSliderOption();\r\n this.setNodeJustify();\r\n this.setSubject();\r\n this.setData();\r\n }\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n const { data, layout, justify, activatedIndex } = changes;\r\n XIsChange(data) && this.setData();\r\n XIsChange(layout) && this.setLayout(layout);\r\n XIsChange(justify) && this.cdr.detectChanges();\r\n XIsChange(activatedIndex) && this.setActivatedIndex();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._unSubject.next();\r\n this._unSubject.unsubscribe();\r\n this._resizeObserver?.disconnect();\r\n }\r\n\r\n ngAfterContentInit() {\r\n Promise.resolve().then(() => {\r\n this.setRouter();\r\n });\r\n }\r\n\r\n ngAfterContentChecked(): void {\r\n if (this.tabs.length !== this.listTabs.length) {\r\n this._tabsContentChange.next(`${this.tabs.length}-${this.listTabs.length}`);\r\n }\r\n }\r\n\r\n ngAfterViewInit() {\r\n this.setSliderWidth();\r\n }\r\n\r\n setSliderWidth() {\r\n if (this.slider && this.actionsRef) {\r\n XResize(this.actionsRef.nativeElement)\r\n .pipe(takeUntil(this._unSubject))\r\n .subscribe((x) => {\r\n this._resizeObserver = x.resizeObserver;\r\n this.renderer.setStyle(\r\n this.slider.elementRef.nativeElement,\r\n 'width',\r\n `calc(100% - ${this.actionsRef.nativeElement.clientWidth}px)`\r\n );\r\n });\r\n }\r\n }\r\n\r\n setSubject() {\r\n this._tabsContentChange.pipe(distinctUntilChanged(), takeUntil(this._unSubject)).subscribe(() => {\r\n this.setData();\r\n });\r\n }\r\n\r\n setRouter() {\r\n if (!this.linkRouter) return;\r\n if (!this.router) {\r\n console.warn(`${XTabsPrefix}: you should import 'RouterModule' if you want to use 'linkRouter'!`);\r\n return;\r\n }\r\n this.router.events\r\n .pipe(\r\n filter((x) => x instanceof NavigationEnd),\r\n startWith(true),\r\n takeUntil(this._unSubject)\r\n )\r\n .subscribe(() => {\r\n this.updateRouterActive();\r\n this.cdr.markForCheck();\r\n });\r\n }\r\n\r\n updateRouterActive() {\r\n if (!this.router.navigated) return;\r\n const index = this.findShouldActiveTabIndex();\r\n if (index !== -1 && index !== this.activeIndex) {\r\n this.activatedIndex = index;\r\n this.setActivatedIndex();\r\n }\r\n }\r\n\r\n findShouldActiveTabIndex(): number {\r\n const tabs = this.listTabs.toArray();\r\n const isActive = this.isLinkActive(this.router);\r\n return tabs.findIndex((tab) => {\r\n const c = tab.linkDirective;\r\n return c ? isActive(c.routerLink) || isActive(c.routerLinkWithHref) : false;\r\n });\r\n }\r\n\r\n isLinkActive(router: Router): (link?: RouterLink | RouterLinkWithHref) => boolean {\r\n return (link?: RouterLink | RouterLinkWithHref) => {\r\n return link ? router.isActive(link.urlTree!, Boolean(this.linkExact)) : false;\r\n };\r\n }\r\n\r\n activatedChange(index: number) {\r\n this.activatedIndex = index;\r\n this.indexChange.emit({\r\n activatedIndex: index,\r\n activatedTab: this.tabs[index]\r\n });\r\n this.setFirstAndLast();\r\n this.cdr.detectChanges();\r\n }\r\n\r\n setActivatedIndex() {\r\n if (typeof this.sliderOption === 'undefined') {\r\n this.sliderOption = new XSliderProperty();\r\n }\r\n this.sliderOption.activatedIndex = this.activatedIndex;\r\n this.setFirstAndLast();\r\n this.cdr.detectChanges();\r\n }\r\n\r\n private setClassMap() {\r\n this.classMap = {\r\n [`${XTabsPrefix}-${this.layout}`]: !XIsEmpty(this.layout),\r\n [`${XTabsPrefix}-${this.type}`]: !XIsEmpty(this.type)\r\n };\r\n }\r\n\r\n private setLayout(layout: SimpleChange) {\r\n this.classMap[`${XTabsPrefix}-${layout.previousValue}`] = false;\r\n this.classMap[`${XTabsPrefix}-${layout.currentValue}`] = true;\r\n this.setSliderOption();\r\n this.cdr.detectChanges();\r\n }\r\n\r\n private setNodeJustify() {\r\n this.nodeJustify = this.nodeJustify ? this.nodeJustify : this.layout === 'left' ? 'end' : this.layout === 'right' ? 'start' : 'center';\r\n }\r\n\r\n private setData() {\r\n let data = [];\r\n if (XIsEmpty(this.data)) {\r\n if (this.listTabs && this.listTabs.length > 0) {\r\n let _data: any[] = [];\r\n this.listTabs.forEach((x, index) => {\r\n const label = x.linkTemplateDirective?.templateRef || x.label;\r\n const id = x.label || index;\r\n _data = [...(_data as XTabsNode[]), { id: id, label: label, disabled: x.disabled }];\r\n });\r\n data = _data;\r\n } else {\r\n data = [];\r\n\r\n return;\r\n }\r\n }\r\n XSetData<XTabsNode>(data, this._unSubject).subscribe((x) => {\r\n this.tabs = x;\r\n if (!this.sliderHidden && !this.actionTpl) {\r\n this.sliderHidden = this.tabs.length <= 1;\r\n }\r\n this.sliderOption.data = this.tabs;\r\n this.setActivatedIndex();\r\n this.cdr.detectChanges();\r\n });\r\n }\r\n\r\n private setSliderOption() {\r\n this.sliderOption.layout = ['top', 'bottom'].indexOf(this.layout) !== -1 ? 'row' : 'column';\r\n }\r\n\r\n private setFirstAndLast() {\r\n this.classMap[`${XTabsPrefix}-is-first`] = this.activatedIndex === 0;\r\n this.classMap[`${XTabsPrefix}-is-last`] = this.activatedIndex === this.tabs?.length - 1;\r\n }\r\n}\r\n","<div class=\"x-tabs\" [ngClass]=\"classMap\">\r\n <div #list class=\"x-tabs-list\" *ngIf=\"!sliderHidden\">\r\n <x-slider\r\n #slider\r\n [animated]=\"animated && type !== 'tag'\"\r\n [justify]=\"justify\"\r\n [nodeJustify]=\"nodeJustify\"\r\n [data]=\"sliderOption.data\"\r\n [layout]=\"sliderOption.layout\"\r\n [size]=\"size\"\r\n [nodeTpl]=\"nodeTpl\"\r\n [activatedIndex]=\"sliderOption.activatedIndex\"\r\n [showExpand]=\"showExpand\"\r\n [expandMaxHeight]=\"expandMaxHeight\"\r\n (indexChange)=\"activatedChange($event)\"\r\n ></x-slider>\r\n <div #actionsRef class=\"x-tabs-actions\" *ngIf=\"actionTpl\">\r\n <ng-container *ngTemplateOutlet=\"actionTpl\"></ng-container>\r\n </div>\r\n </div>\r\n <div #content class=\"x-tabs-contents\" [class.x-tabs-contents-animated]=\"animated && (layout === 'top' || layout === 'bottom')\">\r\n <x-tab-content\r\n *ngFor=\"let tab of listTabs; index as i\"\r\n [active]=\"activeIndex == i\"\r\n [content]=\"tab.content\"\r\n [class.x-tab-content-unactivated]=\"activeIndex != i\"\r\n [class.x-tab-content-disabled]=\"tab.disabled\"\r\n [style.transform]=\"'translate(' + (-activeIndex || 0) * 100 + '%, 0px)'\"\r\n >\r\n </x-tab-content>\r\n </div>\r\n</div>\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { XTabsComponent } from './tabs.component';\r\nimport { XIconModule } from '@ng-nest/ui/icon';\r\nimport { XSliderModule } from '@ng-nest/ui/slider';\r\nimport { XTabComponent } from './tab.component';\r\nimport { XTabContentComponent } from './tab-content.component';\r\nimport { XTabsProperty, XTabProperty } from './tabs.property';\r\nimport { XButtonModule } from '@ng-nest/ui/button';\r\nimport { XTabLinkTemplateDirective, XTabLinkDirective } from './tab-link.directive';\r\n\r\n@NgModule({\r\n declarations: [\r\n XTabsComponent,\r\n XTabContentComponent,\r\n XTabComponent,\r\n XTabLinkDirective,\r\n XTabLinkTemplateDirective,\r\n XTabsProperty,\r\n XTabProperty\r\n ],\r\n exports: [XTabsComponent, XTabContentComponent, XTabComponent, XTabLinkDirective, XTabLinkTemplateDirective],\r\n imports: [CommonModule, XSliderModule, XButtonModule, XIconModule]\r\n})\r\nexport class XTabsModule {}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["i1","i2","i5.XTabContentComponent"],"mappings":";;;;;;;;;;;;;;;AAeA;;;;AAIG;AACI,MAAM,WAAW,GAAG,SAAS;AACpC,MAAM,aAAa,GAAG,MAAM,CAAC;AAE7B;;AAEG;AAEG,MAAO,aAAc,SAAQ,SAAS,CAAA;AAD5C,IAAA,WAAA,GAAA;;AAEE;;;AAGG;AACM,QAAA,IAAI,CAAA,IAAA,GAAqB,EAAE,CAAC;AACrC;;;AAGG;AACM,QAAA,IAAO,CAAA,OAAA,GAAa,OAAO,CAAC;AACrC;;;AAGG;AACM,QAAA,IAAI,CAAA,IAAA,GAAc,OAAO,CAAC;AACnC;;;AAGG;AACM,QAAA,IAAM,CAAA,MAAA,GAAgB,KAAK,CAAC;AACrC;;;AAGG;AACsB,QAAA,IAAc,CAAA,cAAA,GAAY,CAAC,CAAC;AACrD;;;AAGG;AACuB,QAAA,IAAQ,CAAA,QAAA,GAAa,IAAI,CAAC;AAyCpD;;;AAGG;AACuB,QAAA,IAAS,CAAA,SAAA,GAAc,IAAI,CAAC;AACtD;;;AAGG;AACO,QAAA,IAAA,CAAA,WAAW,GAAG,IAAI,YAAY,EAAiB,CAAC;KAC3D;;6HAjFY,aAAa,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAb,mBAAA,aAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,aAAa,8dADH,EAAE,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,CAAA;AA0BE,UAAA,CAAA;AAAf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A,OAAA,EAAA,CAAA,cAAc,EAAE,oBAAoB,EAAE,aAAa,EAAE,iBAAiB,EAAE,yBAAyB,CAAA,EAAA,CAAA,CAAA;AAGhG,mBAAA,WAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,WAAW,YAFZ,YAAY,EAAE,aAAa,EAAE,aAAa,EAAE,WAAW,CAAA,EAAA,CAAA,CAAA;2FAEtD,WAAW,EAAA,UAAA,EAAA,CAAA;kBAbvB,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,YAAY,EAAE;wBACZ,cAAc;wBACd,oBAAoB;wBACpB,aAAa;wBACb,iBAAiB;wBACjB,yBAAyB;wBACzB,aAAa;wBACb,YAAY;AACb,qBAAA;oBACD,OAAO,EAAE,CAAC,cAAc,EAAE,oBAAoB,EAAE,aAAa,EAAE,iBAAiB,EAAE,yBAAyB,CAAC;oBAC5G,OAAO,EAAE,CAAC,YAAY,EAAE,aAAa,EAAE,aAAa,EAAE,WAAW,CAAC;iBACnE,CAAA;;;ACvBD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"ng-nest-ui-tabs.mjs","sources":["../../../../lib/ng-nest/ui/tabs/tabs.property.ts","../../../../lib/ng-nest/ui/tabs/tab-link.directive.ts","../../../../lib/ng-nest/ui/tabs/tab.component.ts","../../../../lib/ng-nest/ui/tabs/tab.component.html","../../../../lib/ng-nest/ui/tabs/tab-content.component.ts","../../../../lib/ng-nest/ui/tabs/tab-content.component.html","../../../../lib/ng-nest/ui/tabs/tabs.component.ts","../../../../lib/ng-nest/ui/tabs/tabs.component.html","../../../../lib/ng-nest/ui/tabs/tabs.module.ts","../../../../lib/ng-nest/ui/tabs/ng-nest-ui-tabs.ts"],"sourcesContent":["import {\r\n XData,\r\n XJustify,\r\n XProperty,\r\n XInputBoolean,\r\n XSize,\r\n XIdentityProperty,\r\n XTemplate,\r\n XInputNumber,\r\n XNumber,\r\n XBoolean,\r\n XWithConfig\r\n} from '@ng-nest/ui/core';\r\nimport { Input, TemplateRef, Output, EventEmitter, Component } from '@angular/core';\r\n\r\n/**\r\n * Tabs\r\n * @selector x-tabs\r\n * @decorator component\r\n */\r\nexport const XTabsPrefix = 'x-tabs';\r\nconst X_CONFIG_NAME = 'tabs';\r\n\r\n/**\r\n * Tabs Property\r\n */\r\n@Component({ template: '' })\r\nexport class XTabsProperty extends XProperty {\r\n /**\r\n * @zh_CN Data 数据\r\n * @en_US Data\r\n */\r\n @Input() data: XData<XTabsNode> = [];\r\n /**\r\n * @zh_CN 对齐方式\r\n * @en_US Alignment\r\n */\r\n @Input() justify: XJustify = 'start';\r\n /**\r\n * @zh_CN 样式\r\n * @en_US Style\r\n */\r\n @Input() type: XTabsType = 'block';\r\n /**\r\n * @zh_CN 布局方式\r\n * @en_US Layout\r\n */\r\n @Input() layout: XTabsLayout = 'top';\r\n /**\r\n * @zh_CN 激活的序号\r\n * @en_US Activation number\r\n */\r\n @Input() @XInputNumber() activatedIndex: XNumber = 0;\r\n /**\r\n * @zh_CN 动画\r\n * @en_US Animation\r\n */\r\n @Input() @XInputBoolean() animated: XBoolean = true;\r\n /**\r\n * @zh_CN 节点模板\r\n * @en_US Node template\r\n */\r\n @Input() nodeTpl!: TemplateRef<any>;\r\n /**\r\n * @zh_CN 尺寸\r\n * @en_US Size\r\n */\r\n @Input() @XWithConfig<XSize>(X_CONFIG_NAME, 'medium') size?: XSize;\r\n /**\r\n * @zh_CN 节点排列方式\r\n * @en_US Node arrangement\r\n */\r\n @Input() nodeJustify?: XJustify;\r\n /**\r\n * @zh_CN 隐藏标签栏,只有一个标签页时候默认隐藏(存在自定义操作模版的时候不会)\r\n * @en_US Hide the label bar, there is only one tab, the default hidden\r\n */\r\n @Input() @XInputBoolean() sliderHidden?: XBoolean;\r\n /**\r\n * @zh_CN 标签栏上的自定义操作模版\r\n * @en_US Custom template on the label bar\r\n */\r\n @Input() actionTpl?: TemplateRef<void>;\r\n /**\r\n * @zh_CN 标签页显示不下的时候显示展开所有的按钮,布局为 top 、bottom 的时候生效\r\n * @en_US When the node is not displayed, display all the buttons, and the arrangement is effective when the arrangement is row\r\n */\r\n @Input() @XWithConfig<XBoolean>(X_CONFIG_NAME, false) @XInputBoolean() showExpand?: XBoolean;\r\n /**\r\n * @zh_CN 展开所有弹框的最大高度\r\n * @en_US Expand the maximum height of all bomb frames\r\n */\r\n @Input() @XWithConfig<string>(X_CONFIG_NAME, '15rem') expandMaxHeight?: string;\r\n /**\r\n * @zh_CN angular 路由联动\r\n * @en_US Link angular router\r\n */\r\n @Input() @XInputBoolean() linkRouter?: XBoolean;\r\n /**\r\n * @zh_CN 以严格匹配模式确定联动的路由\r\n * @en_US Determine the linked route in strict matching mode\r\n */\r\n @Input() @XInputBoolean() linkExact?: XBoolean = true;\r\n /**\r\n * @zh_CN 标签切换变化的事件\r\n * @en_US Label switching event\r\n */\r\n @Output() indexChange = new EventEmitter<XActivatedTab>();\r\n}\r\n\r\n/**\r\n * @zh_CN Tabs 数据对象\r\n * @en_US Tabs data object\r\n */\r\nexport interface XTabsNode extends XIdentityProperty {\r\n /**\r\n * @zh_CN 禁用节点\r\n * @en_US Node disabled\r\n */\r\n disabled?: boolean;\r\n /**\r\n * @zh_CN 自定义属性\r\n * @en_US Custom properties\r\n */\r\n [property: string]: any;\r\n}\r\n\r\n/**\r\n * @zh_CN 激活的tab\r\n * @en_US Active tab\r\n */\r\nexport interface XActivatedTab {\r\n activatedIndex?: number;\r\n activatedTab?: XTabsNode;\r\n}\r\n\r\n/**\r\n * @zh_CN 样式类型\r\n * @en_US Style type\r\n */\r\nexport type XTabsType = 'block' | 'tag' | 'card';\r\n\r\n/**\r\n * @zh_CN 布局方式\r\n * @en_US Layout\r\n */\r\nexport type XTabsLayout = 'top' | 'right' | 'bottom' | 'left';\r\n\r\n/**\r\n * Tab\r\n * @selector x-tab\r\n * @decorator component\r\n */\r\nexport const XTabPrefix = 'x-tab';\r\n\r\n/**\r\n * Tab Property\r\n */\r\n@Component({ template: '' })\r\nexport class XTabProperty {\r\n /**\r\n * @zh_CN 标签名称,支持自定义模板\r\n * @en_US Label name, support custom template\r\n */\r\n @Input() label?: XTemplate;\r\n /**\r\n * @zh_CN 禁用\r\n * @en_US Disabeld\r\n */\r\n @Input() @XInputBoolean() disabled?: XBoolean;\r\n}\r\n","import { Directive, ElementRef, Host, Optional, Self, TemplateRef } from '@angular/core';\r\nimport { RouterLink, RouterLinkWithHref } from '@angular/router';\r\n\r\n@Directive({\r\n selector: 'ng-template[xTabLink]',\r\n exportAs: 'xTabLinkTemplate'\r\n})\r\nexport class XTabLinkTemplateDirective {\r\n constructor(@Host() public templateRef: TemplateRef<void>) {}\r\n}\r\n\r\n@Directive({\r\n selector: 'a[x-tab-link]',\r\n exportAs: 'xTabLink'\r\n})\r\nexport class XTabLinkDirective {\r\n constructor(\r\n public elementRef: ElementRef,\r\n @Optional() @Self() public routerLink?: RouterLink,\r\n @Optional() @Self() public routerLinkWithHref?: RouterLinkWithHref\r\n ) {}\r\n}\r\n","import { ChangeDetectionStrategy, Component, ContentChild, TemplateRef, ViewChild, ViewEncapsulation } from '@angular/core';\r\nimport { XTabPrefix, XTabProperty } from './tabs.property';\r\nimport { XConfigService } from '@ng-nest/ui/core';\r\nimport { XTabLinkDirective, XTabLinkTemplateDirective } from './tab-link.directive';\r\n\r\n@Component({\r\n selector: `${XTabPrefix}`,\r\n templateUrl: './tab.component.html',\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class XTabComponent extends XTabProperty {\r\n @ViewChild('contentTpl', { static: true }) content!: TemplateRef<void>;\r\n @ContentChild(XTabLinkTemplateDirective, { static: false }) linkTemplateDirective!: XTabLinkTemplateDirective;\r\n @ContentChild(XTabLinkDirective, { static: false }) linkDirective!: XTabLinkDirective;\r\n\r\n constructor(public configService: XConfigService) {\r\n super();\r\n }\r\n}\r\n","<ng-template #tabLinkTpl>\r\n <ng-content select=\"[x-tab-link]\"></ng-content>\r\n</ng-template>\r\n<ng-template #contentTpl>\r\n <ng-content></ng-content>\r\n</ng-template>\r\n","import {\r\n ChangeDetectionStrategy,\r\n Component,\r\n Input,\r\n TemplateRef,\r\n ViewEncapsulation,\r\n ElementRef,\r\n Renderer2\r\n} from '@angular/core';\r\nimport { XBoolean } from '@ng-nest/ui/core';\r\n\r\n@Component({\r\n selector: 'x-tab-content',\r\n preserveWhitespaces: false,\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n templateUrl: './tab-content.component.html'\r\n})\r\nexport class XTabContentComponent {\r\n @Input() content!: TemplateRef<void>;\r\n @Input() active: XBoolean = false;\r\n constructor(private elementRef: ElementRef, private renderer: Renderer2) {\r\n this.renderer.addClass(this.elementRef.nativeElement, 'x-tab-content');\r\n }\r\n}\r\n","<ng-container>\r\n <ng-template [ngTemplateOutlet]=\"content\"></ng-template>\r\n</ng-container>\r\n","import {\r\n Component,\r\n OnInit,\r\n ChangeDetectionStrategy,\r\n OnChanges,\r\n SimpleChanges,\r\n ChangeDetectorRef,\r\n ContentChildren,\r\n ViewChild,\r\n ViewEncapsulation,\r\n SimpleChange,\r\n QueryList,\r\n ElementRef,\r\n Renderer2,\r\n Optional\r\n} from '@angular/core';\r\nimport { XTabsPrefix, XTabsNode, XTabsProperty } from './tabs.property';\r\nimport { XIsChange, XSetData, XIsEmpty, XConfigService, XResize } from '@ng-nest/ui/core';\r\nimport { Subject, takeUntil, distinctUntilChanged, filter, startWith, delay } from 'rxjs';\r\nimport { XSliderComponent, XSliderProperty } from '@ng-nest/ui/slider';\r\nimport { XTabComponent } from './tab.component';\r\nimport { NavigationEnd, Router, RouterLink, RouterLinkWithHref } from '@angular/router';\r\n\r\n@Component({\r\n selector: `${XTabsPrefix}`,\r\n templateUrl: './tabs.component.html',\r\n styleUrls: ['./style/index.scss'],\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class XTabsComponent extends XTabsProperty implements OnInit, OnChanges {\r\n sliderOption = new XSliderProperty();\r\n tabs: XTabsNode[] = [];\r\n private _unSubject = new Subject<void>();\r\n private _tabsContentChange = new Subject<string>();\r\n private _resizeObserver!: ResizeObserver;\r\n\r\n get activeIndex() {\r\n return Number(this.activatedIndex);\r\n }\r\n\r\n @ContentChildren(XTabComponent) listTabs!: QueryList<XTabComponent>;\r\n\r\n @ViewChild(XSliderComponent, { static: false }) slider!: XSliderComponent;\r\n @ViewChild('actionsRef', { static: false }) actionsRef!: ElementRef;\r\n\r\n constructor(\r\n private cdr: ChangeDetectorRef,\r\n public configService: XConfigService,\r\n public renderer: Renderer2,\r\n @Optional() private router: Router\r\n ) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.setClassMap();\r\n this.setSliderOption();\r\n this.setNodeJustify();\r\n this.setSubject();\r\n this.setData();\r\n }\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n const { data, layout, justify, activatedIndex } = changes;\r\n XIsChange(data) && this.setData();\r\n XIsChange(layout) && this.setLayout(layout);\r\n XIsChange(justify) && this.cdr.detectChanges();\r\n XIsChange(activatedIndex) && this.setActivatedIndex();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this._unSubject.next();\r\n this._unSubject.unsubscribe();\r\n this._resizeObserver?.disconnect();\r\n }\r\n\r\n ngAfterContentChecked(): void {\r\n if (this.tabs.length !== this.listTabs.length) {\r\n this._tabsContentChange.next(`${this.tabs.length}-${this.listTabs.length}`);\r\n }\r\n }\r\n\r\n ngAfterViewInit() {\r\n this.setSliderWidth();\r\n Promise.resolve().then(() => {\r\n this.setRouter();\r\n });\r\n }\r\n\r\n setSliderWidth() {\r\n if (this.slider && this.actionsRef) {\r\n XResize(this.actionsRef.nativeElement)\r\n .pipe(takeUntil(this._unSubject))\r\n .subscribe((x) => {\r\n this._resizeObserver = x.resizeObserver;\r\n this.renderer.setStyle(\r\n this.slider.elementRef.nativeElement,\r\n 'width',\r\n `calc(100% - ${this.actionsRef.nativeElement.clientWidth}px)`\r\n );\r\n });\r\n }\r\n }\r\n\r\n setSubject() {\r\n this._tabsContentChange.pipe(distinctUntilChanged(), takeUntil(this._unSubject)).subscribe(() => {\r\n this.setData();\r\n });\r\n }\r\n\r\n setRouter() {\r\n if (!this.linkRouter) return;\r\n if (!this.router) {\r\n console.warn(`${XTabsPrefix}: you should import 'RouterModule' if you want to use 'linkRouter'!`);\r\n return;\r\n }\r\n this.router.events\r\n .pipe(\r\n filter((x) => x instanceof NavigationEnd),\r\n startWith(true),\r\n delay(0),\r\n takeUntil(this._unSubject)\r\n )\r\n .subscribe(() => {\r\n this.updateRouterActive();\r\n this.cdr.markForCheck();\r\n });\r\n }\r\n\r\n updateRouterActive() {\r\n if (!this.router.navigated) return;\r\n const index = this.findShouldActiveTabIndex();\r\n if (index !== -1 && index !== this.activeIndex) {\r\n this.activatedIndex = index;\r\n this.setActivatedIndex();\r\n }\r\n }\r\n\r\n findShouldActiveTabIndex(): number {\r\n const tabs = this.listTabs.toArray();\r\n const isActive = this.isLinkActive(this.router);\r\n\r\n return tabs.findIndex((tab) => {\r\n const c = tab.linkDirective;\r\n return c ? isActive(c.routerLink) || isActive(c.routerLinkWithHref) : false;\r\n });\r\n }\r\n\r\n isLinkActive(router: Router): (link?: RouterLink | RouterLinkWithHref) => boolean {\r\n return (link?: RouterLink | RouterLinkWithHref) => {\r\n return link ? router.isActive(link.urlTree!, Boolean(this.linkExact)) : false;\r\n };\r\n }\r\n\r\n activatedChange(index: number) {\r\n this.activatedIndex = index;\r\n this.indexChange.emit({\r\n activatedIndex: index,\r\n activatedTab: this.tabs[index]\r\n });\r\n this.setFirstAndLast();\r\n this.cdr.detectChanges();\r\n }\r\n\r\n setActivatedIndex() {\r\n if (typeof this.sliderOption === 'undefined') {\r\n this.sliderOption = new XSliderProperty();\r\n }\r\n this.sliderOption.activatedIndex = this.activatedIndex;\r\n this.setFirstAndLast();\r\n this.cdr.detectChanges();\r\n }\r\n\r\n private setClassMap() {\r\n this.classMap = {\r\n [`${XTabsPrefix}-${this.layout}`]: !XIsEmpty(this.layout),\r\n [`${XTabsPrefix}-${this.type}`]: !XIsEmpty(this.type)\r\n };\r\n }\r\n\r\n private setLayout(layout: SimpleChange) {\r\n this.classMap[`${XTabsPrefix}-${layout.previousValue}`] = false;\r\n this.classMap[`${XTabsPrefix}-${layout.currentValue}`] = true;\r\n this.setSliderOption();\r\n this.cdr.detectChanges();\r\n }\r\n\r\n private setNodeJustify() {\r\n this.nodeJustify = this.nodeJustify ? this.nodeJustify : this.layout === 'left' ? 'end' : this.layout === 'right' ? 'start' : 'center';\r\n }\r\n\r\n private setData() {\r\n let data = [];\r\n if (XIsEmpty(this.data)) {\r\n if (this.listTabs && this.listTabs.length > 0) {\r\n let _data: any[] = [];\r\n this.listTabs.forEach((x, index) => {\r\n const label = x.linkTemplateDirective?.templateRef || x.label;\r\n const id = x.label || index;\r\n _data = [...(_data as XTabsNode[]), { id: id, label: label, disabled: x.disabled }];\r\n });\r\n data = _data;\r\n } else {\r\n data = [];\r\n\r\n return;\r\n }\r\n }\r\n XSetData<XTabsNode>(data, this._unSubject).subscribe((x) => {\r\n this.tabs = x;\r\n if (!this.sliderHidden && !this.actionTpl) {\r\n this.sliderHidden = this.tabs.length <= 1;\r\n }\r\n this.sliderOption.data = this.tabs;\r\n this.setActivatedIndex();\r\n this.cdr.detectChanges();\r\n });\r\n }\r\n\r\n private setSliderOption() {\r\n this.sliderOption.layout = ['top', 'bottom'].indexOf(this.layout) !== -1 ? 'row' : 'column';\r\n }\r\n\r\n private setFirstAndLast() {\r\n this.classMap[`${XTabsPrefix}-is-first`] = this.activatedIndex === 0;\r\n this.classMap[`${XTabsPrefix}-is-last`] = this.activatedIndex === this.tabs?.length - 1;\r\n }\r\n}\r\n","<div class=\"x-tabs\" [ngClass]=\"classMap\">\r\n <div #list class=\"x-tabs-list\" *ngIf=\"!sliderHidden\">\r\n <x-slider\r\n #slider\r\n [animated]=\"animated && type !== 'tag'\"\r\n [justify]=\"justify\"\r\n [nodeJustify]=\"nodeJustify\"\r\n [data]=\"sliderOption.data\"\r\n [layout]=\"sliderOption.layout\"\r\n [size]=\"size\"\r\n [nodeTpl]=\"nodeTpl\"\r\n [activatedIndex]=\"sliderOption.activatedIndex\"\r\n [showExpand]=\"showExpand\"\r\n [expandMaxHeight]=\"expandMaxHeight\"\r\n (indexChange)=\"activatedChange($event)\"\r\n ></x-slider>\r\n <div #actionsRef class=\"x-tabs-actions\" *ngIf=\"actionTpl\">\r\n <ng-container *ngTemplateOutlet=\"actionTpl\"></ng-container>\r\n </div>\r\n </div>\r\n <div #content class=\"x-tabs-contents\" [class.x-tabs-contents-animated]=\"animated && (layout === 'top' || layout === 'bottom')\">\r\n <x-tab-content\r\n *ngFor=\"let tab of listTabs; index as i\"\r\n [active]=\"activeIndex == i\"\r\n [content]=\"tab.content\"\r\n [class.x-tab-content-unactivated]=\"activeIndex != i\"\r\n [class.x-tab-content-disabled]=\"tab.disabled\"\r\n [style.transform]=\"'translate(' + (-activeIndex || 0) * 100 + '%, 0px)'\"\r\n >\r\n </x-tab-content>\r\n </div>\r\n</div>\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { XTabsComponent } from './tabs.component';\r\nimport { XIconModule } from '@ng-nest/ui/icon';\r\nimport { XSliderModule } from '@ng-nest/ui/slider';\r\nimport { XTabComponent } from './tab.component';\r\nimport { XTabContentComponent } from './tab-content.component';\r\nimport { XTabsProperty, XTabProperty } from './tabs.property';\r\nimport { XButtonModule } from '@ng-nest/ui/button';\r\nimport { XTabLinkTemplateDirective, XTabLinkDirective } from './tab-link.directive';\r\n\r\n@NgModule({\r\n declarations: [\r\n XTabsComponent,\r\n XTabContentComponent,\r\n XTabComponent,\r\n XTabLinkDirective,\r\n XTabLinkTemplateDirective,\r\n XTabsProperty,\r\n XTabProperty\r\n ],\r\n exports: [XTabsComponent, XTabContentComponent, XTabComponent, XTabLinkDirective, XTabLinkTemplateDirective],\r\n imports: [CommonModule, XSliderModule, XButtonModule, XIconModule]\r\n})\r\nexport class XTabsModule {}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["i1","i2","i5.XTabContentComponent"],"mappings":";;;;;;;;;;;;;;;AAeA;;;;AAIG;AACI,MAAM,WAAW,GAAG,SAAS;AACpC,MAAM,aAAa,GAAG,MAAM,CAAC;AAE7B;;AAEG;AAEG,MAAO,aAAc,SAAQ,SAAS,CAAA;AAD5C,IAAA,WAAA,GAAA;;AAEE;;;AAGG;AACM,QAAA,IAAI,CAAA,IAAA,GAAqB,EAAE,CAAC;AACrC;;;AAGG;AACM,QAAA,IAAO,CAAA,OAAA,GAAa,OAAO,CAAC;AACrC;;;AAGG;AACM,QAAA,IAAI,CAAA,IAAA,GAAc,OAAO,CAAC;AACnC;;;AAGG;AACM,QAAA,IAAM,CAAA,MAAA,GAAgB,KAAK,CAAC;AACrC;;;AAGG;AACsB,QAAA,IAAc,CAAA,cAAA,GAAY,CAAC,CAAC;AACrD;;;AAGG;AACuB,QAAA,IAAQ,CAAA,QAAA,GAAa,IAAI,CAAC;AAyCpD;;;AAGG;AACuB,QAAA,IAAS,CAAA,SAAA,GAAc,IAAI,CAAC;AACtD;;;AAGG;AACO,QAAA,IAAA,CAAA,WAAW,GAAG,IAAI,YAAY,EAAiB,CAAC;KAC3D;;6HAjFY,aAAa,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAb,mBAAA,aAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,aAAa,8dADH,EAAE,EAAA,QAAA,EAAA,IAAA,EAA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Y,EAAE,aAAa,EAAE,aAAa,EAAE,WAAW,CADvD,EAAA,OAAA,EAAA,CAAA,cAAc,EAAE,oBAAoB,EAAE,aAAa,EAAE,iBAAiB,EAAE,yBAAyB,CAAA,EAAA,CAAA,CAAA;AAGhG,mBAAA,WAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,WAAW,YAFZ,YAAY,EAAE,aAAa,EAAE,aAAa,EAAE,WAAW,CAAA,EAAA,CAAA,CAAA;2FAEtD,WAAW,EAAA,UAAA,EAAA,CAAA;kBAbvB,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,YAAY,EAAE;wBACZ,cAAc;wBACd,oBAAoB;wBACpB,aAAa;wBACb,iBAAiB;wBACjB,yBAAyB;wBACzB,aAAa;wBACb,YAAY;AACb,qBAAA;oBACD,OAAO,EAAE,CAAC,cAAc,EAAE,oBAAoB,EAAE,aAAa,EAAE,iBAAiB,EAAE,yBAAyB,CAAC;oBAC5G,OAAO,EAAE,CAAC,YAAY,EAAE,aAAa,EAAE,aAAa,EAAE,WAAW,CAAC;iBACnE,CAAA;;;ACvBD;;AAEG;;;;"}
|
|
@@ -131,6 +131,7 @@ class XAnchorComponent extends XAnchorProperty {
|
|
|
131
131
|
}
|
|
132
132
|
];
|
|
133
133
|
});
|
|
134
|
+
console.log(list);
|
|
134
135
|
this.sliderData = list;
|
|
135
136
|
}
|
|
136
137
|
}
|
|
@@ -176,10 +177,10 @@ class XAnchorComponent extends XAnchorProperty {
|
|
|
176
177
|
}
|
|
177
178
|
}
|
|
178
179
|
/** @nocollapse */ XAnchorComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.0.2", ngImport: i0, type: XAnchorComponent, deps: [{ token: i0.Renderer2 }, { token: i0.ElementRef }, { token: i0.ChangeDetectorRef }, { token: DOCUMENT }, { token: i1.XConfigService }], target: i0.ɵɵFactoryTarget.Component });
|
|
179
|
-
/** @nocollapse */ XAnchorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.0.2", type: XAnchorComponent, selector: "x-anchor", viewQueries: [{ propertyName: "anchor", first: true, predicate: ["anchor"], descendants: true, static: true }, { propertyName: "content", first: true, predicate: ["content"], descendants: true, static: true }], usesInheritance: true, ngImport: i0, template: "<div #anchor class=\"x-anchor\" [ngClass]=\"classMap\">\r\n <div #content class=\"x-anchor-content\">\r\n <ng-content></ng-content>\r\n </div>\r\n <x-affix class=\"x-anchor-affix\" [top]=\"affixTop\">\r\n <div class=\"x-anchor-slider\" [style.height.px]=\"sliderHeight\">\r\n <x-slider\r\n [data]=\"sliderData\"\r\n layout=\"column\"\r\n [activatedIndex]=\"activatedIndex\"\r\n [nodeJustify]=\"justify\"\r\n [nodeTpl]=\"sliderNodeTpl\"\r\n (indexChange)=\"activatedChange($event)\"\r\n ></x-slider>\r\n </div>\r\n </x-affix>\r\n</div>\r\n\r\n<ng-template #sliderNodeTpl let-node=\"$node\">\r\n <span [style.padding-left.rem]=\"node.left - 1\">{{ node.label }}</span>\r\n</ng-template>\r\n", styles: [".x-anchor{margin:0;padding:0;display:flex}.x-anchor-content{flex:1}.x-anchor-affix{display:block}.x-anchor-slider{float:left;overflow:hidden}.x-anchor-slider:hover{overflow-y:auto}.x-anchor-right{flex-direction:row}.x-anchor-right .x-anchor-slider .x-slider-column>.x-slider-scroll{overflow-y:auto}.x-anchor-right .x-anchor-slider .x-slider-column>.x-slider-scroll>ul>li{border-left:.125rem solid var(--x-border)}.x-anchor-right .x-anchor-slider .x-slider-column>.x-slider-scroll>ul>li.x-slider-highlight{border:none;border-top-left-radius:0;border-bottom-left-radius:0;z-index:2;border-left:.125rem solid var(--x-primary)}.x-anchor-left{flex-direction:row-reverse}.x-anchor-left .x-anchor-slider .x-slider-column>.x-slider-scroll{overflow-y:auto}.x-anchor-left .x-anchor-slider .x-slider-column>.x-slider-scroll>ul>li{border-right:.125rem solid var(--x-border)}.x-anchor-left .x-anchor-slider .x-slider-column>.x-slider-scroll>ul>li.x-slider-highlight{border:none;border-top-right-radius:0;border-bottom-right-radius:0;z-index:2;border-right:.125rem solid var(--x-primary)}\n"], dependencies: [{ kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: i3.XAffixComponent, selector: "x-affix" }, { kind: "component", type: i4.XSliderComponent, selector: "x-slider" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
180
|
+
/** @nocollapse */ XAnchorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.0.2", type: XAnchorComponent, selector: "x-anchor", viewQueries: [{ propertyName: "anchor", first: true, predicate: ["anchor"], descendants: true, static: true }, { propertyName: "content", first: true, predicate: ["content"], descendants: true, static: true }], usesInheritance: true, ngImport: i0, template: "<div #anchor class=\"x-anchor\" [ngClass]=\"classMap\">\r\n <div #content class=\"x-anchor-content\">\r\n <ng-content></ng-content>\r\n </div>\r\n <x-affix class=\"x-anchor-affix\" [top]=\"affixTop\">\r\n <div class=\"x-anchor-slider\" [style.height.px]=\"sliderHeight\">\r\n <x-slider\r\n [data]=\"sliderData\"\r\n layout=\"column\"\r\n [activatedIndex]=\"activatedIndex\"\r\n [nodeJustify]=\"justify\"\r\n [nodeTpl]=\"sliderNodeTpl\"\r\n [showAnchor]=\"true\"\r\n (indexChange)=\"activatedChange($event)\"\r\n ></x-slider>\r\n </div>\r\n </x-affix>\r\n</div>\r\n\r\n<ng-template #sliderNodeTpl let-node=\"$node\">\r\n <span [style.padding-left.rem]=\"node.left - 1\">{{ node.label }}</span>\r\n</ng-template>\r\n", styles: [".x-anchor{margin:0;padding:0;display:flex}.x-anchor-content{flex:1}.x-anchor-affix{display:block}.x-anchor-slider{float:left;overflow:hidden}.x-anchor-slider:hover{overflow-y:auto}.x-anchor-right{flex-direction:row}.x-anchor-right .x-anchor-slider .x-slider-column>.x-slider-scroll{overflow-y:auto}.x-anchor-right .x-anchor-slider .x-slider-column>.x-slider-scroll>ul>li{border-left:.125rem solid var(--x-border)}.x-anchor-right .x-anchor-slider .x-slider-column>.x-slider-scroll>ul>li.x-slider-highlight{border:none;border-top-left-radius:0;border-bottom-left-radius:0;z-index:2;border-left:.125rem solid var(--x-primary)}.x-anchor-left{flex-direction:row-reverse}.x-anchor-left .x-anchor-slider .x-slider-column>.x-slider-scroll{overflow-y:auto}.x-anchor-left .x-anchor-slider .x-slider-column>.x-slider-scroll>ul>li{border-right:.125rem solid var(--x-border)}.x-anchor-left .x-anchor-slider .x-slider-column>.x-slider-scroll>ul>li.x-slider-highlight{border:none;border-top-right-radius:0;border-bottom-right-radius:0;z-index:2;border-right:.125rem solid var(--x-primary)}\n"], dependencies: [{ kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: i3.XAffixComponent, selector: "x-affix" }, { kind: "component", type: i4.XSliderComponent, selector: "x-slider" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
180
181
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.0.2", ngImport: i0, type: XAnchorComponent, decorators: [{
|
|
181
182
|
type: Component,
|
|
182
|
-
args: [{ selector: `${XAnchorPrefix}`, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<div #anchor class=\"x-anchor\" [ngClass]=\"classMap\">\r\n <div #content class=\"x-anchor-content\">\r\n <ng-content></ng-content>\r\n </div>\r\n <x-affix class=\"x-anchor-affix\" [top]=\"affixTop\">\r\n <div class=\"x-anchor-slider\" [style.height.px]=\"sliderHeight\">\r\n <x-slider\r\n [data]=\"sliderData\"\r\n layout=\"column\"\r\n [activatedIndex]=\"activatedIndex\"\r\n [nodeJustify]=\"justify\"\r\n [nodeTpl]=\"sliderNodeTpl\"\r\n (indexChange)=\"activatedChange($event)\"\r\n ></x-slider>\r\n </div>\r\n </x-affix>\r\n</div>\r\n\r\n<ng-template #sliderNodeTpl let-node=\"$node\">\r\n <span [style.padding-left.rem]=\"node.left - 1\">{{ node.label }}</span>\r\n</ng-template>\r\n", styles: [".x-anchor{margin:0;padding:0;display:flex}.x-anchor-content{flex:1}.x-anchor-affix{display:block}.x-anchor-slider{float:left;overflow:hidden}.x-anchor-slider:hover{overflow-y:auto}.x-anchor-right{flex-direction:row}.x-anchor-right .x-anchor-slider .x-slider-column>.x-slider-scroll{overflow-y:auto}.x-anchor-right .x-anchor-slider .x-slider-column>.x-slider-scroll>ul>li{border-left:.125rem solid var(--x-border)}.x-anchor-right .x-anchor-slider .x-slider-column>.x-slider-scroll>ul>li.x-slider-highlight{border:none;border-top-left-radius:0;border-bottom-left-radius:0;z-index:2;border-left:.125rem solid var(--x-primary)}.x-anchor-left{flex-direction:row-reverse}.x-anchor-left .x-anchor-slider .x-slider-column>.x-slider-scroll{overflow-y:auto}.x-anchor-left .x-anchor-slider .x-slider-column>.x-slider-scroll>ul>li{border-right:.125rem solid var(--x-border)}.x-anchor-left .x-anchor-slider .x-slider-column>.x-slider-scroll>ul>li.x-slider-highlight{border:none;border-top-right-radius:0;border-bottom-right-radius:0;z-index:2;border-right:.125rem solid var(--x-primary)}\n"] }]
|
|
183
|
+
args: [{ selector: `${XAnchorPrefix}`, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<div #anchor class=\"x-anchor\" [ngClass]=\"classMap\">\r\n <div #content class=\"x-anchor-content\">\r\n <ng-content></ng-content>\r\n </div>\r\n <x-affix class=\"x-anchor-affix\" [top]=\"affixTop\">\r\n <div class=\"x-anchor-slider\" [style.height.px]=\"sliderHeight\">\r\n <x-slider\r\n [data]=\"sliderData\"\r\n layout=\"column\"\r\n [activatedIndex]=\"activatedIndex\"\r\n [nodeJustify]=\"justify\"\r\n [nodeTpl]=\"sliderNodeTpl\"\r\n [showAnchor]=\"true\"\r\n (indexChange)=\"activatedChange($event)\"\r\n ></x-slider>\r\n </div>\r\n </x-affix>\r\n</div>\r\n\r\n<ng-template #sliderNodeTpl let-node=\"$node\">\r\n <span [style.padding-left.rem]=\"node.left - 1\">{{ node.label }}</span>\r\n</ng-template>\r\n", styles: [".x-anchor{margin:0;padding:0;display:flex}.x-anchor-content{flex:1}.x-anchor-affix{display:block}.x-anchor-slider{float:left;overflow:hidden}.x-anchor-slider:hover{overflow-y:auto}.x-anchor-right{flex-direction:row}.x-anchor-right .x-anchor-slider .x-slider-column>.x-slider-scroll{overflow-y:auto}.x-anchor-right .x-anchor-slider .x-slider-column>.x-slider-scroll>ul>li{border-left:.125rem solid var(--x-border)}.x-anchor-right .x-anchor-slider .x-slider-column>.x-slider-scroll>ul>li.x-slider-highlight{border:none;border-top-left-radius:0;border-bottom-left-radius:0;z-index:2;border-left:.125rem solid var(--x-primary)}.x-anchor-left{flex-direction:row-reverse}.x-anchor-left .x-anchor-slider .x-slider-column>.x-slider-scroll{overflow-y:auto}.x-anchor-left .x-anchor-slider .x-slider-column>.x-slider-scroll>ul>li{border-right:.125rem solid var(--x-border)}.x-anchor-left .x-anchor-slider .x-slider-column>.x-slider-scroll>ul>li.x-slider-highlight{border:none;border-top-right-radius:0;border-bottom-right-radius:0;z-index:2;border-right:.125rem solid var(--x-primary)}\n"] }]
|
|
183
184
|
}], ctorParameters: function () { return [{ type: i0.Renderer2 }, { type: i0.ElementRef }, { type: i0.ChangeDetectorRef }, { type: undefined, decorators: [{
|
|
184
185
|
type: Inject,
|
|
185
186
|
args: [DOCUMENT]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ng-nest-ui-anchor.mjs","sources":["../../../../lib/ng-nest/ui/anchor/anchor.property.ts","../../../../lib/ng-nest/ui/anchor/anchor.component.ts","../../../../lib/ng-nest/ui/anchor/anchor.component.html","../../../../lib/ng-nest/ui/anchor/anchor.module.ts","../../../../lib/ng-nest/ui/anchor/ng-nest-ui-anchor.ts"],"sourcesContent":["import { XIdentityProperty, XProperty, XJustify, XWithConfig, XPositionLeftRight } from '@ng-nest/ui/core';\r\nimport { Input, Component } from '@angular/core';\r\n\r\n/**\r\n * Anchor\r\n * @selector x-anchor\r\n * @decorator component\r\n */\r\nexport const XAnchorPrefix = 'x-anchor';\r\nconst X_CONFIG_NAME = 'anchor';\r\n\r\n/**\r\n * Anchor Property\r\n */\r\n@Component({ template: '' })\r\nexport class XAnchorProperty extends XProperty {\r\n /**\r\n * @zh_CN 滚动区域对象\r\n * @en_US Scroll area object\r\n */\r\n @Input() scroll!: HTMLElement;\r\n /**\r\n * @zh_CN 顶部距离\r\n * @en_US Top distance\r\n */\r\n @Input() @XWithConfig<string>(X_CONFIG_NAME, '0') affixTop!: string;\r\n /**\r\n * @zh_CN 导航相对内容位置\r\n * @en_US Navigation relative content position\r\n */\r\n @Input() @XWithConfig<XAnchorLayout>(X_CONFIG_NAME, 'right') layout!: XAnchorLayout;\r\n /**\r\n * @zh_CN 对齐方式\r\n * @en_US Alignment\r\n */\r\n @Input() @XWithConfig<XJustify>(X_CONFIG_NAME, 'start') justify!: XJustify;\r\n}\r\n\r\n/**\r\n * Anchor Node\r\n */\r\nexport interface XAnchorNode extends XIdentityProperty {\r\n /**\r\n * @zh_CN 左内边距,用来显示层级\r\n * @en_US Left inner margin, used to display hierarchy\r\n */\r\n left?: number;\r\n /**\r\n * @zh_CN 图标\r\n * @en_US Icon\r\n */\r\n icon?: string;\r\n /**\r\n * @zh_CN 锚点的链接\r\n * @en_US Anchor link\r\n */\r\n link?: string;\r\n}\r\n\r\n/**\r\n * @zh_CN 布局方式,相对内容的位置\r\n * @en_US Layout method, relative content position\r\n */\r\nexport type XAnchorLayout = XPositionLeftRight;\r\n","import {\r\n Component,\r\n OnInit,\r\n ViewEncapsulation,\r\n Renderer2,\r\n ElementRef,\r\n ChangeDetectorRef,\r\n ChangeDetectionStrategy,\r\n ViewChild,\r\n AfterViewInit,\r\n Inject,\r\n OnDestroy\r\n} from '@angular/core';\r\nimport { XAnchorPrefix, XAnchorNode, XAnchorProperty } from './anchor.property';\r\nimport { computedStyle, XIsEmpty, reqAnimFrame, XIsNumber, XIsUndefined, XConfigService } from '@ng-nest/ui/core';\r\nimport { XSliderNode } from '@ng-nest/ui/slider';\r\nimport { DOCUMENT } from '@angular/common';\r\nimport { fromEvent, Subject } from 'rxjs';\r\nimport { throttleTime, takeUntil } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: `${XAnchorPrefix}`,\r\n templateUrl: './anchor.component.html',\r\n styleUrls: ['./anchor.component.scss'],\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class XAnchorComponent extends XAnchorProperty implements OnInit, AfterViewInit, OnDestroy {\r\n @ViewChild('anchor', { static: true }) anchor!: ElementRef;\r\n @ViewChild('content', { static: true }) content!: ElementRef;\r\n hElements: HTMLElement[] = [];\r\n sliderData: XSliderNode[] = [];\r\n activatedIndex: number = 0;\r\n sliderHeight?: number;\r\n document: Document;\r\n private _scrolling = false;\r\n private _fontSize: number;\r\n private _unSubject = new Subject<void>();\r\n\r\n constructor(\r\n public renderer: Renderer2,\r\n public elementRef: ElementRef,\r\n public cdr: ChangeDetectorRef,\r\n @Inject(DOCUMENT) doc: any,\r\n public configService: XConfigService\r\n ) {\r\n super();\r\n this.document = doc;\r\n this._fontSize = parseFloat(computedStyle(this.document.documentElement, 'font-size'));\r\n }\r\n\r\n ngOnInit() {\r\n this.setClassMap();\r\n this.setSliderData();\r\n this.setHeight();\r\n }\r\n\r\n ngAfterViewInit() {\r\n this.setScroll();\r\n }\r\n\r\n ngOnDestroy() {\r\n this._unSubject.next();\r\n this._unSubject.unsubscribe();\r\n }\r\n\r\n activatedChange(index: number) {\r\n if (XIsEmpty(this.hElements) || XIsUndefined(this.scroll)) return;\r\n\r\n this._scrolling = true;\r\n const hElement = this.hElements[index];\r\n let scrollTop = hElement.offsetTop - this.anchor.nativeElement.offsetTop - parseFloat(computedStyle(hElement, 'margin-top'));\r\n let maxScrollTop = this.scroll.scrollHeight - this.scroll.clientHeight;\r\n if (scrollTop > maxScrollTop) scrollTop = maxScrollTop;\r\n this.scrollTo(this.scroll, parseInt(`${scrollTop}`), 150);\r\n }\r\n\r\n private setClassMap() {\r\n this.classMap[`${XAnchorPrefix}-${this.layout}`] = !XIsEmpty(this.layout);\r\n }\r\n\r\n private setScroll() {\r\n fromEvent(this.scroll ? this.scroll : window, 'scroll')\r\n .pipe(throttleTime(10), takeUntil(this._unSubject))\r\n .subscribe(() => {\r\n if (this._scrolling) return;\r\n this.setActivatedByScroll();\r\n });\r\n if (!this.scroll) {\r\n this.scroll = this.document.documentElement;\r\n }\r\n }\r\n\r\n private setActivatedByScroll() {\r\n let now = 0;\r\n this.hElements.forEach((h, index) => {\r\n let distance = this.scroll.scrollTop + this.anchor.nativeElement.offsetTop;\r\n if (distance >= h.offsetTop) {\r\n now = index;\r\n return;\r\n }\r\n });\r\n this.activatedIndex = now;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n private setSliderData() {\r\n this.hElements = this.content.nativeElement.querySelectorAll(':scope> h1,:scope> h2,:scope> h3,:scope> h4,:scope> h5');\r\n if (this.hElements.length > 0) {\r\n let list: XAnchorNode[] = [];\r\n this.hElements.forEach((x: HTMLElement, i: number) => {\r\n const link = `x-anchor-${i}`;\r\n const left = this.setLeft(x);\r\n this.renderer.setAttribute(x, 'id', link);\r\n list = [\r\n ...list,\r\n {\r\n id: i,\r\n label: x.innerText,\r\n left: left,\r\n link: link\r\n }\r\n ];\r\n });\r\n this.sliderData = list;\r\n }\r\n }\r\n\r\n private setLeft(element: HTMLElement): number {\r\n const eles = ['H1', 'H2', 'H3', 'H4', 'H5'];\r\n const index = eles.indexOf(element.tagName);\r\n return index + 1;\r\n }\r\n\r\n private setHeight() {\r\n if (this.scroll) {\r\n let height = this.scroll.offsetHeight;\r\n let top = parseFloat(computedStyle(this.scroll, 'padding-top'));\r\n let borderTop = parseFloat(computedStyle(this.scroll, 'border-top'));\r\n let bottom = parseFloat(computedStyle(this.scroll, 'padding-bottom'));\r\n let borderBottom = parseFloat(computedStyle(this.scroll, 'border-bottom'));\r\n this.sliderHeight = height - top - bottom - borderTop - borderBottom - this.getTop();\r\n }\r\n }\r\n\r\n private getTop() {\r\n if (this.affixTop === '0') return 0;\r\n if (XIsNumber(this.affixTop)) return Number(this.affixTop);\r\n else if (this.affixTop.indexOf('rem') !== -1) return Number(this.affixTop.replace(/rem/g, '')) * this._fontSize;\r\n else if (this.affixTop.indexOf('px') !== -1) return Number(this.affixTop.replace(/px/g, ''));\r\n return 0;\r\n }\r\n\r\n private scrollTo(element: HTMLElement, to: number, duration: number) {\r\n const difference = to - element.scrollTop;\r\n const perTick = (difference / duration) * 10;\r\n reqAnimFrame(() => {\r\n element.scrollTop = element.scrollTop + perTick;\r\n if (element.scrollTop === to || duration <= 0) {\r\n setTimeout(() => (this._scrolling = false), 20);\r\n return;\r\n } else {\r\n this.scrollTo(element, to, duration - 10);\r\n }\r\n });\r\n }\r\n}\r\n","<div #anchor class=\"x-anchor\" [ngClass]=\"classMap\">\r\n <div #content class=\"x-anchor-content\">\r\n <ng-content></ng-content>\r\n </div>\r\n <x-affix class=\"x-anchor-affix\" [top]=\"affixTop\">\r\n <div class=\"x-anchor-slider\" [style.height.px]=\"sliderHeight\">\r\n <x-slider\r\n [data]=\"sliderData\"\r\n layout=\"column\"\r\n [activatedIndex]=\"activatedIndex\"\r\n [nodeJustify]=\"justify\"\r\n [nodeTpl]=\"sliderNodeTpl\"\r\n (indexChange)=\"activatedChange($event)\"\r\n ></x-slider>\r\n </div>\r\n </x-affix>\r\n</div>\r\n\r\n<ng-template #sliderNodeTpl let-node=\"$node\">\r\n <span [style.padding-left.rem]=\"node.left - 1\">{{ node.label }}</span>\r\n</ng-template>\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { XAnchorComponent } from './anchor.component';\r\nimport { XAffixModule } from '@ng-nest/ui/affix';\r\nimport { XSliderModule } from '@ng-nest/ui/slider';\r\nimport { XAnchorProperty } from './anchor.property';\r\n\r\n@NgModule({\r\n declarations: [XAnchorComponent, XAnchorProperty],\r\n exports: [XAnchorComponent],\r\n imports: [CommonModule, XAffixModule, XSliderModule]\r\n})\r\nexport class XAnchorModule {}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;;;;AAGA;;;;AAIG;AACI,MAAM,aAAa,GAAG,WAAW;AACxC,MAAM,aAAa,GAAG,QAAQ,CAAC;AAE/B;;AAEG;AAEG,MAAO,eAAgB,SAAQ,SAAS,CAAA;;+HAAjC,eAAe,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAf,mBAAA,eAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,eAAe,qKADL,EAAE,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,CAAA;AAW2B,UAAA,CAAA;AAAxC,IAAA,WAAW,CAAS,aAAa,EAAE,GAAG,CAAC;AAAmB,CAAA,EAAA,eAAA,CAAA,SAAA,EAAA,UAAA,EAAA,KAAA,CAAA,CAAA,CAAA;AAKP,UAAA,CAAA;AAAnD,IAAA,WAAW,CAAgB,aAAa,EAAE,OAAO,CAAC;AAAwB,CAAA,EAAA,eAAA,CAAA,SAAA,EAAA,QAAA,EAAA,KAAA,CAAA,CAAA,CAAA;AAK5B,UAAA,CAAA;AAA9C,IAAA,WAAW,CAAW,aAAa,EAAE,OAAO,CAAC;AAAoB,CAAA,EAAA,eAAA,CAAA,SAAA,EAAA,SAAA,EAAA,KAAA,CAAA,CAAA,CAAA;2FApBhE,eAAe,EAA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../../../../lib/ng-nest/ui/anchor/anchor.component.ts","../../../../lib/ng-nest/ui/anchor/anchor.component.html","../../../../lib/ng-nest/ui/anchor/anchor.module.ts","../../../../lib/ng-nest/ui/anchor/ng-nest-ui-anchor.ts"],"sourcesContent":["import { XIdentityProperty, XProperty, XJustify, XWithConfig, XPositionLeftRight } from '@ng-nest/ui/core';\r\nimport { Input, Component } from '@angular/core';\r\n\r\n/**\r\n * Anchor\r\n * @selector x-anchor\r\n * @decorator component\r\n */\r\nexport const XAnchorPrefix = 'x-anchor';\r\nconst X_CONFIG_NAME = 'anchor';\r\n\r\n/**\r\n * Anchor Property\r\n */\r\n@Component({ template: '' })\r\nexport class XAnchorProperty extends XProperty {\r\n /**\r\n * @zh_CN 滚动区域对象\r\n * @en_US Scroll area object\r\n */\r\n @Input() scroll!: HTMLElement;\r\n /**\r\n * @zh_CN 顶部距离\r\n * @en_US Top distance\r\n */\r\n @Input() @XWithConfig<string>(X_CONFIG_NAME, '0') affixTop!: string;\r\n /**\r\n * @zh_CN 导航相对内容位置\r\n * @en_US Navigation relative content position\r\n */\r\n @Input() @XWithConfig<XAnchorLayout>(X_CONFIG_NAME, 'right') layout!: XAnchorLayout;\r\n /**\r\n * @zh_CN 对齐方式\r\n * @en_US Alignment\r\n */\r\n @Input() @XWithConfig<XJustify>(X_CONFIG_NAME, 'start') justify!: XJustify;\r\n}\r\n\r\n/**\r\n * Anchor Node\r\n */\r\nexport interface XAnchorNode extends XIdentityProperty {\r\n /**\r\n * @zh_CN 左内边距,用来显示层级\r\n * @en_US Left inner margin, used to display hierarchy\r\n */\r\n left?: number;\r\n /**\r\n * @zh_CN 图标\r\n * @en_US Icon\r\n */\r\n icon?: string;\r\n /**\r\n * @zh_CN 锚点的链接\r\n * @en_US Anchor link\r\n */\r\n link?: string;\r\n}\r\n\r\n/**\r\n * @zh_CN 布局方式,相对内容的位置\r\n * @en_US Layout method, relative content position\r\n */\r\nexport type XAnchorLayout = XPositionLeftRight;\r\n","import {\r\n Component,\r\n OnInit,\r\n ViewEncapsulation,\r\n Renderer2,\r\n ElementRef,\r\n ChangeDetectorRef,\r\n ChangeDetectionStrategy,\r\n ViewChild,\r\n AfterViewInit,\r\n Inject,\r\n OnDestroy\r\n} from '@angular/core';\r\nimport { XAnchorPrefix, XAnchorNode, XAnchorProperty } from './anchor.property';\r\nimport { computedStyle, XIsEmpty, reqAnimFrame, XIsNumber, XIsUndefined, XConfigService } from '@ng-nest/ui/core';\r\nimport { XSliderNode } from '@ng-nest/ui/slider';\r\nimport { DOCUMENT } from '@angular/common';\r\nimport { fromEvent, Subject } from 'rxjs';\r\nimport { throttleTime, takeUntil } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: `${XAnchorPrefix}`,\r\n templateUrl: './anchor.component.html',\r\n styleUrls: ['./anchor.component.scss'],\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class XAnchorComponent extends XAnchorProperty implements OnInit, AfterViewInit, OnDestroy {\r\n @ViewChild('anchor', { static: true }) anchor!: ElementRef;\r\n @ViewChild('content', { static: true }) content!: ElementRef;\r\n hElements: HTMLElement[] = [];\r\n sliderData: XSliderNode[] = [];\r\n activatedIndex: number = 0;\r\n sliderHeight?: number;\r\n document: Document;\r\n private _scrolling = false;\r\n private _fontSize: number;\r\n private _unSubject = new Subject<void>();\r\n\r\n constructor(\r\n public renderer: Renderer2,\r\n public elementRef: ElementRef,\r\n public cdr: ChangeDetectorRef,\r\n @Inject(DOCUMENT) doc: any,\r\n public configService: XConfigService\r\n ) {\r\n super();\r\n this.document = doc;\r\n this._fontSize = parseFloat(computedStyle(this.document.documentElement, 'font-size'));\r\n }\r\n\r\n ngOnInit() {\r\n this.setClassMap();\r\n this.setSliderData();\r\n this.setHeight();\r\n }\r\n\r\n ngAfterViewInit() {\r\n this.setScroll();\r\n }\r\n\r\n ngOnDestroy() {\r\n this._unSubject.next();\r\n this._unSubject.unsubscribe();\r\n }\r\n\r\n activatedChange(index: number) {\r\n if (XIsEmpty(this.hElements) || XIsUndefined(this.scroll)) return;\r\n\r\n this._scrolling = true;\r\n const hElement = this.hElements[index];\r\n let scrollTop = hElement.offsetTop - this.anchor.nativeElement.offsetTop - parseFloat(computedStyle(hElement, 'margin-top'));\r\n let maxScrollTop = this.scroll.scrollHeight - this.scroll.clientHeight;\r\n if (scrollTop > maxScrollTop) scrollTop = maxScrollTop;\r\n this.scrollTo(this.scroll, parseInt(`${scrollTop}`), 150);\r\n }\r\n\r\n private setClassMap() {\r\n this.classMap[`${XAnchorPrefix}-${this.layout}`] = !XIsEmpty(this.layout);\r\n }\r\n\r\n private setScroll() {\r\n fromEvent(this.scroll ? this.scroll : window, 'scroll')\r\n .pipe(throttleTime(10), takeUntil(this._unSubject))\r\n .subscribe(() => {\r\n if (this._scrolling) return;\r\n this.setActivatedByScroll();\r\n });\r\n if (!this.scroll) {\r\n this.scroll = this.document.documentElement;\r\n }\r\n }\r\n\r\n private setActivatedByScroll() {\r\n let now = 0;\r\n this.hElements.forEach((h, index) => {\r\n let distance = this.scroll.scrollTop + this.anchor.nativeElement.offsetTop;\r\n if (distance >= h.offsetTop) {\r\n now = index;\r\n return;\r\n }\r\n });\r\n this.activatedIndex = now;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n private setSliderData() {\r\n this.hElements = this.content.nativeElement.querySelectorAll(':scope> h1,:scope> h2,:scope> h3,:scope> h4,:scope> h5');\r\n if (this.hElements.length > 0) {\r\n let list: XAnchorNode[] = [];\r\n this.hElements.forEach((x: HTMLElement, i: number) => {\r\n const link = `x-anchor-${i}`;\r\n const left = this.setLeft(x);\r\n this.renderer.setAttribute(x, 'id', link);\r\n list = [\r\n ...list,\r\n {\r\n id: i,\r\n label: x.innerText,\r\n left: left,\r\n link: link\r\n }\r\n ];\r\n });\r\n console.log(list)\r\n this.sliderData = list;\r\n }\r\n }\r\n\r\n private setLeft(element: HTMLElement): number {\r\n const eles = ['H1', 'H2', 'H3', 'H4', 'H5'];\r\n const index = eles.indexOf(element.tagName);\r\n return index + 1;\r\n }\r\n\r\n private setHeight() {\r\n if (this.scroll) {\r\n let height = this.scroll.offsetHeight;\r\n let top = parseFloat(computedStyle(this.scroll, 'padding-top'));\r\n let borderTop = parseFloat(computedStyle(this.scroll, 'border-top'));\r\n let bottom = parseFloat(computedStyle(this.scroll, 'padding-bottom'));\r\n let borderBottom = parseFloat(computedStyle(this.scroll, 'border-bottom'));\r\n this.sliderHeight = height - top - bottom - borderTop - borderBottom - this.getTop();\r\n }\r\n }\r\n\r\n private getTop() {\r\n if (this.affixTop === '0') return 0;\r\n if (XIsNumber(this.affixTop)) return Number(this.affixTop);\r\n else if (this.affixTop.indexOf('rem') !== -1) return Number(this.affixTop.replace(/rem/g, '')) * this._fontSize;\r\n else if (this.affixTop.indexOf('px') !== -1) return Number(this.affixTop.replace(/px/g, ''));\r\n return 0;\r\n }\r\n\r\n private scrollTo(element: HTMLElement, to: number, duration: number) {\r\n const difference = to - element.scrollTop;\r\n const perTick = (difference / duration) * 10;\r\n reqAnimFrame(() => {\r\n element.scrollTop = element.scrollTop + perTick;\r\n if (element.scrollTop === to || duration <= 0) {\r\n setTimeout(() => (this._scrolling = false), 20);\r\n return;\r\n } else {\r\n this.scrollTo(element, to, duration - 10);\r\n }\r\n });\r\n }\r\n}\r\n","<div #anchor class=\"x-anchor\" [ngClass]=\"classMap\">\r\n <div #content class=\"x-anchor-content\">\r\n <ng-content></ng-content>\r\n </div>\r\n <x-affix class=\"x-anchor-affix\" [top]=\"affixTop\">\r\n <div class=\"x-anchor-slider\" [style.height.px]=\"sliderHeight\">\r\n <x-slider\r\n [data]=\"sliderData\"\r\n layout=\"column\"\r\n [activatedIndex]=\"activatedIndex\"\r\n [nodeJustify]=\"justify\"\r\n [nodeTpl]=\"sliderNodeTpl\"\r\n [showAnchor]=\"true\"\r\n (indexChange)=\"activatedChange($event)\"\r\n ></x-slider>\r\n </div>\r\n </x-affix>\r\n</div>\r\n\r\n<ng-template #sliderNodeTpl let-node=\"$node\">\r\n <span [style.padding-left.rem]=\"node.left - 1\">{{ node.label }}</span>\r\n</ng-template>\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { XAnchorComponent } from './anchor.component';\r\nimport { XAffixModule } from '@ng-nest/ui/affix';\r\nimport { XSliderModule } from '@ng-nest/ui/slider';\r\nimport { XAnchorProperty } from './anchor.property';\r\n\r\n@NgModule({\r\n declarations: [XAnchorComponent, XAnchorProperty],\r\n exports: [XAnchorComponent],\r\n imports: [CommonModule, XAffixModule, XSliderModule]\r\n})\r\nexport class XAnchorModule {}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;;;;AAGA;;;;AAIG;AACI,MAAM,aAAa,GAAG,WAAW;AACxC,MAAM,aAAa,GAAG,QAAQ,CAAC;AAE/B;;AAEG;AAEG,MAAO,eAAgB,SAAQ,SAAS,CAAA;;+HAAjC,eAAe,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAf,mBAAA,eAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,eAAe,qKADL,EAAE,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,CAAA;AAW2B,UAAA,CAAA;AAAxC,IAAA,WAAW,CAAS,aAAa,EAAE,GAAG,CAAC;AAAmB,CAAA,EAAA,eAAA,CAAA,SAAA,EAAA,UAAA,EAAA,KAAA,CAAA,CAAA,CAAA;AAKP,UAAA,CAAA;AAAnD,IAAA,WAAW,CAAgB,aAAa,EAAE,OAAO,CAAC;AAAwB,CAAA,EAAA,eAAA,CAAA,SAAA,EAAA,QAAA,EAAA,KAAA,CAAA,CAAA,CAAA;AAK5B,UAAA,CAAA;AAA9C,IAAA,WAA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AA,OAAO,EAAE,CAAC,YAAY,EAAE,YAAY,EAAE,aAAa,CAAC;AACrD,iBAAA,CAAA;;;ACXD;;AAEG;;;;"}
|
|
@@ -2,6 +2,7 @@ import * as i0 from '@angular/core';
|
|
|
2
2
|
import { Component, Input, ViewEncapsulation, ChangeDetectionStrategy, HostBinding, Optional, Host, NgModule } from '@angular/core';
|
|
3
3
|
import * as i1 from '@ng-nest/ui/core';
|
|
4
4
|
import { XProperty, XWithConfig, XInputBoolean, XInputNumber, XIsChange, XClearClass, XIsEmpty } from '@ng-nest/ui/core';
|
|
5
|
+
import { of, delay } from 'rxjs';
|
|
5
6
|
import { __decorate } from 'tslib';
|
|
6
7
|
import * as i3 from '@angular/common';
|
|
7
8
|
import { CommonModule } from '@angular/common';
|
|
@@ -187,6 +188,7 @@ class XButtonComponent extends XButtonProperty {
|
|
|
187
188
|
this.elementRef = elementRef;
|
|
188
189
|
this.renderer = renderer;
|
|
189
190
|
this.configService = configService;
|
|
191
|
+
this.transition = false;
|
|
190
192
|
}
|
|
191
193
|
ngOnInit() {
|
|
192
194
|
this.setSpace();
|
|
@@ -208,6 +210,13 @@ class XButtonComponent extends XButtonProperty {
|
|
|
208
210
|
[`x-size-${this.size}`]: !XIsEmpty(this.size),
|
|
209
211
|
[`x-direction-${this.direction}`]: !XIsEmpty(this.direction)
|
|
210
212
|
};
|
|
213
|
+
if (!this.transition)
|
|
214
|
+
of(true)
|
|
215
|
+
.pipe(delay(0))
|
|
216
|
+
.subscribe(() => {
|
|
217
|
+
this.transition = true;
|
|
218
|
+
this.cdr.detectChanges();
|
|
219
|
+
});
|
|
211
220
|
this.cdr.detectChanges();
|
|
212
221
|
}
|
|
213
222
|
setSpace() {
|
|
@@ -218,10 +227,10 @@ class XButtonComponent extends XButtonProperty {
|
|
|
218
227
|
}
|
|
219
228
|
}
|
|
220
229
|
/** @nocollapse */ XButtonComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.0.2", ngImport: i0, type: XButtonComponent, deps: [{ token: XButtonsComponent, host: true, optional: true }, { token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i0.Renderer2 }, { token: i1.XConfigService }], target: i0.ɵɵFactoryTarget.Component });
|
|
221
|
-
/** @nocollapse */ XButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.0.2", type: XButtonComponent, selector: "x-button", usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<button\r\n class=\"x-button\"\r\n [tabindex]=\"tabindex\"\r\n [ngClass]=\"classMap\"\r\n [class.x-button-only-icon]=\"onlyIcon\"\r\n [class.x-button-activated]=\"activated\"\r\n [class.x-button-disabled]=\"disabled\"\r\n [class.x-button-round]=\"round\"\r\n [class.x-button-circle]=\"circle\"\r\n [class.x-button-icon]=\"icon && !content.innerHTML.trim()\"\r\n [class.x-button-closable]=\"closable\"\r\n [title]=\"title\"\r\n x-ripple\r\n [type]=\"type\"\r\n [disabled]=\"disabled\"\r\n [attr.type]=\"attrType\"\r\n>\r\n <x-icon *ngIf=\"icon && !loading\" [type]=\"icon\"></x-icon>\r\n <x-icon *ngIf=\"loading\" type=\"fto-loader\" [spin]=\"loading\"></x-icon>\r\n <span #content><ng-content></ng-content></span>\r\n</button>\r\n\r\n<!-- \u63D0\u524D\u52A0\u8F7D loading \u7684\u56FE\u6807-->\r\n<x-icon *ngIf=\"loading\" [style.display]=\"'none'\" type=\"fto-loader\"></x-icon>\r\n", styles: ["x-button{display:inline-flex;line-height:initial}.x-button{margin:0;padding:0;border:var(--x-border-width) solid;border-radius:var(--x-border-radius);flex:1;display:inline-flex;align-items:center;justify-content:center;font-size:var(--x-font-size-small);text-align:center;background-clip:border-box;cursor:pointer;-webkit-user-select:none;user-select:none;white-space:nowrap;transition:color var(--x-animation-duration-base) ease-in-out,background-color var(--x-animation-duration-base) ease-in-out,border var(--x-animation-duration-base) ease-in-out}.x-button:focus{outline:none}.x-button>.x-icon{font-size:.925rem}.x-button.x-direction-column{flex-direction:column}.x-button.x-direction-column-reverse{flex-direction:column-reverse}.x-button.x-direction-row{flex-direction:row}.x-button.x-direction-row-reverse{flex-direction:row-reverse}.x-button.x-direction-row>.x-icon{margin-right:.25rem;margin-left:-.25rem}.x-button.x-direction-row-reverse>.x-icon{margin-right:-.25rem;margin-left:.25rem}.x-button-icon.x-direction-row>.x-icon,.x-button-icon.x-direction-row-reverse>.x-icon{margin-right:0;margin-left:0}.x-button-disabled{transform:none!important}.x-button-round{border-radius:5rem}.x-button-circle{border-radius:50%;padding:0;width:1.675rem}.x-button-only-icon,.x-button-only-icon.x-button-initial,.x-button-text{border:none;background-color:transparent;box-shadow:none}.x-button-only-icon:focus,.x-button-only-icon:hover,.x-button-only-icon:active,.x-button-only-icon.x-button-initial:focus,.x-button-only-icon.x-button-initial:hover,.x-button-only-icon.x-button-initial:active,.x-button-text:focus,.x-button-text:hover,.x-button-text:active{color:var(--x-primary);background-color:#0000001a;border-color:transparent}.x-button-closable{color:var(--x-text-400)}.x-button-closable:hover{color:var(--x-text-300)}.x-button-disabled.x-button-activated.x-button-initial{color:var(--x-primary-700);cursor:not-allowed;background-image:none;background-color:var(--x-background);border-color:var(--x-primary-700);box-shadow:none}.x-button-disabled.x-button-activated.x-button-initial:hover,.x-button-disabled.x-button-activated.x-button-initial:active,.x-button-disabled.x-button-activated.x-button-initial:focus{color:var(--x-primary-700);background-color:var(--x-background);border-color:var(--x-primary-700)}.x-button-disabled.x-button-activated.x-button-initial:active .x-button-inner{transform:none}.x-button-disabled.x-button-activated.x-button-initial:hover,.x-button-disabled.x-button-activated.x-button-initial:active{color:var(--x-primary-700);cursor:not-allowed;background-image:none;background-color:var(--x-background);border-color:var(--x-primary-700);box-shadow:none}.x-button-disabled.x-button-activated.x-button-initial:hover:hover,.x-button-disabled.x-button-activated.x-button-initial:hover:active,.x-button-disabled.x-button-activated.x-button-initial:hover:focus,.x-button-disabled.x-button-activated.x-button-initial:active:hover,.x-button-disabled.x-button-activated.x-button-initial:active:active,.x-button-disabled.x-button-activated.x-button-initial:active:focus{color:var(--x-primary-700);background-color:var(--x-background);border-color:var(--x-primary-700)}.x-button-disabled.x-button-activated.x-button-initial:hover:active .x-button-inner,.x-button-disabled.x-button-activated.x-button-initial:active:active .x-button-inner{transform:none}.x-button-disabled.x-button-text,.x-button-disabled.x-button-only-icon{color:var(--x-text-400);cursor:not-allowed;background-image:none;background-color:transparent;border-color:transparent;box-shadow:none}.x-button-disabled.x-button-text:hover,.x-button-disabled.x-button-text:active,.x-button-disabled.x-button-text:focus,.x-button-disabled.x-button-only-icon:hover,.x-button-disabled.x-button-only-icon:active,.x-button-disabled.x-button-only-icon:focus{color:var(--x-text-400);background-color:transparent;border-color:transparent}.x-button-disabled.x-button-text:active .x-button-inner,.x-button-disabled.x-button-only-icon:active .x-button-inner{transform:none}.x-button-disabled.x-button-text:hover,.x-button-disabled.x-button-text:active,.x-button-disabled.x-button-only-icon:hover,.x-button-disabled.x-button-only-icon:active{color:var(--x-text-400);cursor:not-allowed;background-image:none;background-color:transparent;border-color:transparent;box-shadow:none}.x-button-disabled.x-button-text:hover:hover,.x-button-disabled.x-button-text:hover:active,.x-button-disabled.x-button-text:hover:focus,.x-button-disabled.x-button-text:active:hover,.x-button-disabled.x-button-text:active:active,.x-button-disabled.x-button-text:active:focus,.x-button-disabled.x-button-only-icon:hover:hover,.x-button-disabled.x-button-only-icon:hover:active,.x-button-disabled.x-button-only-icon:hover:focus,.x-button-disabled.x-button-only-icon:active:hover,.x-button-disabled.x-button-only-icon:active:active,.x-button-disabled.x-button-only-icon:active:focus{color:var(--x-text-400);background-color:transparent;border-color:transparent}.x-button-disabled.x-button-text:hover:active .x-button-inner,.x-button-disabled.x-button-text:active:active .x-button-inner,.x-button-disabled.x-button-only-icon:hover:active .x-button-inner,.x-button-disabled.x-button-only-icon:active:active .x-button-inner{transform:none}.x-button.x-size-big{height:var(--x-height-big);line-height:var(--x-height-big);padding:0 var(--x-padding-big)}.x-button.x-size-large{height:var(--x-height-large);line-height:var(--x-height-large);padding:0 var(--x-padding-large)}.x-button.x-size-medium{height:var(--x-height-medium);line-height:var(--x-height-medium);padding:0 var(--x-padding-medium)}.x-button.x-size-small{height:var(--x-height-small);line-height:var(--x-height-small);padding:0 var(--x-padding-small)}.x-button.x-size-mini{height:var(--x-height-mini);line-height:var(--x-height-mini);padding:0 var(--x-padding-mini)}.x-button-initial{color:var(--x-text);background-color:var(--x-background);border-color:var(--x-border)}.x-button-initial:hover,.x-button-initial:active{color:var(--x-primary);background-color:var(--x-background);border-color:var(--x-primary)}.x-button-initial:focus{color:var(--x-primary);background-color:var(--x-background);border-color:var(--x-primary);box-shadow:var(--x-box-shadow-focus)}.x-button-initial.x-button-disabled{color:var(--x-text-400);cursor:not-allowed;background-image:none;background-color:var(--x-background-200);border-color:var(--x-border);box-shadow:none}.x-button-initial.x-button-disabled:hover,.x-button-initial.x-button-disabled:active,.x-button-initial.x-button-disabled:focus{color:var(--x-text-400);background-color:var(--x-background-200);border-color:var(--x-border)}.x-button-initial.x-button-disabled:active .x-button-inner{transform:none}.x-button-initial-plain{color:var(--x-text);background-color:var(--x-background-a200);border-color:var(--x-border)}.x-button-initial-plain:hover{color:var(--x-primary);background-color:var(--x-background-a200);border-color:var(--x-primary)}.x-button-initial-plain:active{color:var(--x-primary-a100);background-color:var(--x-background-a200);border-color:var(--x-primary-a100)}.x-button-initial-plain:focus{color:var(--x-primary-a100);background-color:var(--x-background-a200);border-color:var(--x-primary-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-initial-plain.x-button-disabled{color:var(--x-text-400);cursor:not-allowed;background-image:none;background-color:var(--x-background-200);border-color:var(--x-border);box-shadow:none}.x-button-initial-plain.x-button-disabled:hover,.x-button-initial-plain.x-button-disabled:active,.x-button-initial-plain.x-button-disabled:focus{color:var(--x-text-400);background-color:var(--x-background-200);border-color:var(--x-border)}.x-button-initial-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-initial.x-button-activated{z-index:2;color:var(--x-primary);background-color:var(--x-background);border-color:var(--x-primary)}.x-button-primary{color:var(--x-white);background-color:var(--x-primary);border-color:var(--x-primary)}.x-button-primary:hover{color:var(--x-white);background-color:var(--x-primary-100);border-color:var(--x-primary-100)}.x-button-primary:active{color:var(--x-white);background-color:var(--x-primary);border-color:var(--x-primary)}.x-button-primary:focus{color:var(--x-white);background-color:var(--x-primary);border-color:var(--x-primary);box-shadow:var(--x-box-shadow-focus)}.x-button-primary.x-button-disabled{color:var(--x-primary-800);cursor:not-allowed;background-image:none;background-color:var(--x-primary-500);border-color:var(--x-primary-500);box-shadow:none}.x-button-primary.x-button-disabled:hover,.x-button-primary.x-button-disabled:active,.x-button-primary.x-button-disabled:focus{color:var(--x-primary-800);background-color:var(--x-primary-500);border-color:var(--x-primary-500)}.x-button-primary.x-button-disabled:active .x-button-inner{transform:none}.x-button-primary-plain{color:var(--x-primary);background-color:var(--x-primary-900);border-color:var(--x-primary-600)}.x-button-primary-plain:hover{color:var(--x-background-900);background-color:var(--x-primary);border-color:var(--x-primary)}.x-button-primary-plain:active{color:var(--x-background-900);background-color:var(--x-primary-a100);border-color:var(--x-primary-a100)}.x-button-primary-plain:focus{color:var(--x-background-900);background-color:var(--x-primary-a100);border-color:var(--x-primary-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-primary-plain.x-button-disabled{color:var(--x-primary-400);cursor:not-allowed;background-image:none;background-color:var(--x-primary-900);border-color:var(--x-primary-800);box-shadow:none}.x-button-primary-plain.x-button-disabled:hover,.x-button-primary-plain.x-button-disabled:active,.x-button-primary-plain.x-button-disabled:focus{color:var(--x-primary-400);background-color:var(--x-primary-900);border-color:var(--x-primary-800)}.x-button-primary-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-primary.x-button-activated{z-index:2;color:var(--x-white);background-color:var(--x-primary);border-color:var(--x-primary)}.x-button-success{color:var(--x-white);background-color:var(--x-success);border-color:var(--x-success)}.x-button-success:hover{color:var(--x-white);background-color:var(--x-success-100);border-color:var(--x-success-100)}.x-button-success:active{color:var(--x-white);background-color:var(--x-success);border-color:var(--x-success)}.x-button-success:focus{color:var(--x-white);background-color:var(--x-success);border-color:var(--x-success);box-shadow:var(--x-box-shadow-focus)}.x-button-success.x-button-disabled{color:var(--x-success-800);cursor:not-allowed;background-image:none;background-color:var(--x-success-500);border-color:var(--x-success-500);box-shadow:none}.x-button-success.x-button-disabled:hover,.x-button-success.x-button-disabled:active,.x-button-success.x-button-disabled:focus{color:var(--x-success-800);background-color:var(--x-success-500);border-color:var(--x-success-500)}.x-button-success.x-button-disabled:active .x-button-inner{transform:none}.x-button-success-plain{color:var(--x-success);background-color:var(--x-success-900);border-color:var(--x-success-600)}.x-button-success-plain:hover{color:var(--x-background-900);background-color:var(--x-success);border-color:var(--x-success)}.x-button-success-plain:active{color:var(--x-background-900);background-color:var(--x-success-a100);border-color:var(--x-success-a100)}.x-button-success-plain:focus{color:var(--x-background-900);background-color:var(--x-success-a100);border-color:var(--x-success-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-success-plain.x-button-disabled{color:var(--x-success-400);cursor:not-allowed;background-image:none;background-color:var(--x-success-900);border-color:var(--x-success-800);box-shadow:none}.x-button-success-plain.x-button-disabled:hover,.x-button-success-plain.x-button-disabled:active,.x-button-success-plain.x-button-disabled:focus{color:var(--x-success-400);background-color:var(--x-success-900);border-color:var(--x-success-800)}.x-button-success-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-success.x-button-activated{z-index:2;color:var(--x-white);background-color:var(--x-success);border-color:var(--x-success)}.x-button-warning{color:var(--x-white);background-color:var(--x-warning);border-color:var(--x-warning)}.x-button-warning:hover{color:var(--x-white);background-color:var(--x-warning-100);border-color:var(--x-warning-100)}.x-button-warning:active{color:var(--x-white);background-color:var(--x-warning);border-color:var(--x-warning)}.x-button-warning:focus{color:var(--x-white);background-color:var(--x-warning);border-color:var(--x-warning);box-shadow:var(--x-box-shadow-focus)}.x-button-warning.x-button-disabled{color:var(--x-warning-800);cursor:not-allowed;background-image:none;background-color:var(--x-warning-500);border-color:var(--x-warning-500);box-shadow:none}.x-button-warning.x-button-disabled:hover,.x-button-warning.x-button-disabled:active,.x-button-warning.x-button-disabled:focus{color:var(--x-warning-800);background-color:var(--x-warning-500);border-color:var(--x-warning-500)}.x-button-warning.x-button-disabled:active .x-button-inner{transform:none}.x-button-warning-plain{color:var(--x-warning);background-color:var(--x-warning-900);border-color:var(--x-warning-600)}.x-button-warning-plain:hover{color:var(--x-background-900);background-color:var(--x-warning);border-color:var(--x-warning)}.x-button-warning-plain:active{color:var(--x-background-900);background-color:var(--x-warning-a100);border-color:var(--x-warning-a100)}.x-button-warning-plain:focus{color:var(--x-background-900);background-color:var(--x-warning-a100);border-color:var(--x-warning-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-warning-plain.x-button-disabled{color:var(--x-warning-400);cursor:not-allowed;background-image:none;background-color:var(--x-warning-900);border-color:var(--x-warning-800);box-shadow:none}.x-button-warning-plain.x-button-disabled:hover,.x-button-warning-plain.x-button-disabled:active,.x-button-warning-plain.x-button-disabled:focus{color:var(--x-warning-400);background-color:var(--x-warning-900);border-color:var(--x-warning-800)}.x-button-warning-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-warning.x-button-activated{z-index:2;color:var(--x-white);background-color:var(--x-warning);border-color:var(--x-warning)}.x-button-danger{color:var(--x-white);background-color:var(--x-danger);border-color:var(--x-danger)}.x-button-danger:hover{color:var(--x-white);background-color:var(--x-danger-100);border-color:var(--x-danger-100)}.x-button-danger:active{color:var(--x-white);background-color:var(--x-danger);border-color:var(--x-danger)}.x-button-danger:focus{color:var(--x-white);background-color:var(--x-danger);border-color:var(--x-danger);box-shadow:var(--x-box-shadow-focus)}.x-button-danger.x-button-disabled{color:var(--x-danger-800);cursor:not-allowed;background-image:none;background-color:var(--x-danger-500);border-color:var(--x-danger-500);box-shadow:none}.x-button-danger.x-button-disabled:hover,.x-button-danger.x-button-disabled:active,.x-button-danger.x-button-disabled:focus{color:var(--x-danger-800);background-color:var(--x-danger-500);border-color:var(--x-danger-500)}.x-button-danger.x-button-disabled:active .x-button-inner{transform:none}.x-button-danger-plain{color:var(--x-danger);background-color:var(--x-danger-900);border-color:var(--x-danger-600)}.x-button-danger-plain:hover{color:var(--x-background-900);background-color:var(--x-danger);border-color:var(--x-danger)}.x-button-danger-plain:active{color:var(--x-background-900);background-color:var(--x-danger-a100);border-color:var(--x-danger-a100)}.x-button-danger-plain:focus{color:var(--x-background-900);background-color:var(--x-danger-a100);border-color:var(--x-danger-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-danger-plain.x-button-disabled{color:var(--x-danger-400);cursor:not-allowed;background-image:none;background-color:var(--x-danger-900);border-color:var(--x-danger-800);box-shadow:none}.x-button-danger-plain.x-button-disabled:hover,.x-button-danger-plain.x-button-disabled:active,.x-button-danger-plain.x-button-disabled:focus{color:var(--x-danger-400);background-color:var(--x-danger-900);border-color:var(--x-danger-800)}.x-button-danger-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-danger.x-button-activated{z-index:2;color:var(--x-white);background-color:var(--x-danger);border-color:var(--x-danger)}.x-button-info{color:var(--x-white);background-color:var(--x-info);border-color:var(--x-info)}.x-button-info:hover{color:var(--x-white);background-color:var(--x-info-100);border-color:var(--x-info-100)}.x-button-info:active{color:var(--x-white);background-color:var(--x-info);border-color:var(--x-info)}.x-button-info:focus{color:var(--x-white);background-color:var(--x-info);border-color:var(--x-info);box-shadow:var(--x-box-shadow-focus)}.x-button-info.x-button-disabled{color:var(--x-info-800);cursor:not-allowed;background-image:none;background-color:var(--x-info-500);border-color:var(--x-info-500);box-shadow:none}.x-button-info.x-button-disabled:hover,.x-button-info.x-button-disabled:active,.x-button-info.x-button-disabled:focus{color:var(--x-info-800);background-color:var(--x-info-500);border-color:var(--x-info-500)}.x-button-info.x-button-disabled:active .x-button-inner{transform:none}.x-button-info-plain{color:var(--x-info);background-color:var(--x-info-900);border-color:var(--x-info-600)}.x-button-info-plain:hover{color:var(--x-background-900);background-color:var(--x-info);border-color:var(--x-info)}.x-button-info-plain:active{color:var(--x-background-900);background-color:var(--x-info-a100);border-color:var(--x-info-a100)}.x-button-info-plain:focus{color:var(--x-background-900);background-color:var(--x-info-a100);border-color:var(--x-info-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-info-plain.x-button-disabled{color:var(--x-info-400);cursor:not-allowed;background-image:none;background-color:var(--x-info-900);border-color:var(--x-info-800);box-shadow:none}.x-button-info-plain.x-button-disabled:hover,.x-button-info-plain.x-button-disabled:active,.x-button-info-plain.x-button-disabled:focus{color:var(--x-info-400);background-color:var(--x-info-900);border-color:var(--x-info-800)}.x-button-info-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-info.x-button-activated{z-index:2;color:var(--x-white);background-color:var(--x-info);border-color:var(--x-info)}\n"], dependencies: [{ kind: "directive", type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i4.XIconComponent, selector: "x-icon" }, { kind: "directive", type: i5.XRippleDirective, selector: "[x-ripple]" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
230
|
+
/** @nocollapse */ XButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.0.2", type: XButtonComponent, selector: "x-button", usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<button\r\n class=\"x-button\"\r\n [tabindex]=\"tabindex\"\r\n [ngClass]=\"classMap\"\r\n [class.x-button-only-icon]=\"onlyIcon\"\r\n [class.x-button-activated]=\"activated\"\r\n [class.x-button-disabled]=\"disabled\"\r\n [class.x-button-round]=\"round\"\r\n [class.x-button-circle]=\"circle\"\r\n [class.x-button-icon]=\"icon && !content.innerHTML.trim()\"\r\n [class.x-button-closable]=\"closable\"\r\n [class.x-button-transition]=\"transition\"\r\n [title]=\"title\"\r\n x-ripple\r\n [type]=\"type\"\r\n [disabled]=\"disabled\"\r\n [attr.type]=\"attrType\"\r\n>\r\n <x-icon *ngIf=\"icon && !loading\" [type]=\"icon\"></x-icon>\r\n <x-icon *ngIf=\"loading\" type=\"fto-loader\" [spin]=\"loading\"></x-icon>\r\n <span #content><ng-content></ng-content></span>\r\n</button>\r\n\r\n<!-- \u63D0\u524D\u52A0\u8F7D loading \u7684\u56FE\u6807-->\r\n<x-icon *ngIf=\"loading\" [style.display]=\"'none'\" type=\"fto-loader\"></x-icon>\r\n", styles: ["x-button{display:inline-flex;line-height:initial}.x-button{margin:0;padding:0;border:var(--x-border-width) solid;border-radius:var(--x-border-radius);flex:1;display:inline-flex;align-items:center;justify-content:center;font-size:var(--x-font-size-small);text-align:center;background-clip:border-box;cursor:pointer;-webkit-user-select:none;user-select:none;white-space:nowrap;touch-action:manipulation;will-change:color,background-color,border}.x-button:focus{outline:none}.x-button>.x-icon{font-size:.925rem}.x-button.x-direction-column{flex-direction:column}.x-button.x-direction-column-reverse{flex-direction:column-reverse}.x-button.x-direction-row{flex-direction:row}.x-button.x-direction-row-reverse{flex-direction:row-reverse}.x-button.x-direction-row>.x-icon{margin-right:.25rem;margin-left:-.25rem}.x-button.x-direction-row-reverse>.x-icon{margin-right:-.25rem;margin-left:.25rem}.x-button-icon.x-direction-row>.x-icon,.x-button-icon.x-direction-row-reverse>.x-icon{margin-right:0;margin-left:0}.x-button-transition{transition:color var(--x-animation-duration-base) ease-in-out,background-color var(--x-animation-duration-base) ease-in-out,border var(--x-animation-duration-base) ease-in-out}.x-button-disabled{transform:none!important}.x-button-round{border-radius:5rem}.x-button-circle{border-radius:50%;padding:0;width:1.675rem}.x-button-only-icon,.x-button-only-icon.x-button-initial,.x-button-text{border:none;background-color:transparent;box-shadow:none}.x-button-only-icon:focus,.x-button-only-icon:hover,.x-button-only-icon:active,.x-button-only-icon.x-button-initial:focus,.x-button-only-icon.x-button-initial:hover,.x-button-only-icon.x-button-initial:active,.x-button-text:focus,.x-button-text:hover,.x-button-text:active{color:var(--x-primary);background-color:#0000001a;border-color:transparent}.x-button-closable{color:var(--x-text-400)}.x-button-closable:hover{color:var(--x-text-300)}.x-button-disabled.x-button-activated.x-button-initial{color:var(--x-primary-700);cursor:not-allowed;background-image:none;background-color:var(--x-background);border-color:var(--x-primary-700);box-shadow:none}.x-button-disabled.x-button-activated.x-button-initial:hover,.x-button-disabled.x-button-activated.x-button-initial:active,.x-button-disabled.x-button-activated.x-button-initial:focus{color:var(--x-primary-700);background-color:var(--x-background);border-color:var(--x-primary-700)}.x-button-disabled.x-button-activated.x-button-initial:active .x-button-inner{transform:none}.x-button-disabled.x-button-activated.x-button-initial:hover,.x-button-disabled.x-button-activated.x-button-initial:active{color:var(--x-primary-700);cursor:not-allowed;background-image:none;background-color:var(--x-background);border-color:var(--x-primary-700);box-shadow:none}.x-button-disabled.x-button-activated.x-button-initial:hover:hover,.x-button-disabled.x-button-activated.x-button-initial:hover:active,.x-button-disabled.x-button-activated.x-button-initial:hover:focus,.x-button-disabled.x-button-activated.x-button-initial:active:hover,.x-button-disabled.x-button-activated.x-button-initial:active:active,.x-button-disabled.x-button-activated.x-button-initial:active:focus{color:var(--x-primary-700);background-color:var(--x-background);border-color:var(--x-primary-700)}.x-button-disabled.x-button-activated.x-button-initial:hover:active .x-button-inner,.x-button-disabled.x-button-activated.x-button-initial:active:active .x-button-inner{transform:none}.x-button-disabled.x-button-text,.x-button-disabled.x-button-only-icon{color:var(--x-text-400);cursor:not-allowed;background-image:none;background-color:transparent;border-color:transparent;box-shadow:none}.x-button-disabled.x-button-text:hover,.x-button-disabled.x-button-text:active,.x-button-disabled.x-button-text:focus,.x-button-disabled.x-button-only-icon:hover,.x-button-disabled.x-button-only-icon:active,.x-button-disabled.x-button-only-icon:focus{color:var(--x-text-400);background-color:transparent;border-color:transparent}.x-button-disabled.x-button-text:active .x-button-inner,.x-button-disabled.x-button-only-icon:active .x-button-inner{transform:none}.x-button-disabled.x-button-text:hover,.x-button-disabled.x-button-text:active,.x-button-disabled.x-button-only-icon:hover,.x-button-disabled.x-button-only-icon:active{color:var(--x-text-400);cursor:not-allowed;background-image:none;background-color:transparent;border-color:transparent;box-shadow:none}.x-button-disabled.x-button-text:hover:hover,.x-button-disabled.x-button-text:hover:active,.x-button-disabled.x-button-text:hover:focus,.x-button-disabled.x-button-text:active:hover,.x-button-disabled.x-button-text:active:active,.x-button-disabled.x-button-text:active:focus,.x-button-disabled.x-button-only-icon:hover:hover,.x-button-disabled.x-button-only-icon:hover:active,.x-button-disabled.x-button-only-icon:hover:focus,.x-button-disabled.x-button-only-icon:active:hover,.x-button-disabled.x-button-only-icon:active:active,.x-button-disabled.x-button-only-icon:active:focus{color:var(--x-text-400);background-color:transparent;border-color:transparent}.x-button-disabled.x-button-text:hover:active .x-button-inner,.x-button-disabled.x-button-text:active:active .x-button-inner,.x-button-disabled.x-button-only-icon:hover:active .x-button-inner,.x-button-disabled.x-button-only-icon:active:active .x-button-inner{transform:none}.x-button.x-size-big{height:var(--x-height-big);line-height:var(--x-height-big);padding:0 var(--x-padding-big)}.x-button.x-size-large{height:var(--x-height-large);line-height:var(--x-height-large);padding:0 var(--x-padding-large)}.x-button.x-size-medium{height:var(--x-height-medium);line-height:var(--x-height-medium);padding:0 var(--x-padding-medium)}.x-button.x-size-small{height:var(--x-height-small);line-height:var(--x-height-small);padding:0 var(--x-padding-small)}.x-button.x-size-mini{height:var(--x-height-mini);line-height:var(--x-height-mini);padding:0 var(--x-padding-mini)}.x-button-initial{color:var(--x-text);background-color:var(--x-background);border-color:var(--x-border)}.x-button-initial:hover,.x-button-initial:active{color:var(--x-primary);background-color:var(--x-background);border-color:var(--x-primary)}.x-button-initial:focus{color:var(--x-primary);background-color:var(--x-background);border-color:var(--x-primary);box-shadow:var(--x-box-shadow-focus)}.x-button-initial.x-button-disabled{color:var(--x-text-400);cursor:not-allowed;background-image:none;background-color:var(--x-background-200);border-color:var(--x-border);box-shadow:none}.x-button-initial.x-button-disabled:hover,.x-button-initial.x-button-disabled:active,.x-button-initial.x-button-disabled:focus{color:var(--x-text-400);background-color:var(--x-background-200);border-color:var(--x-border)}.x-button-initial.x-button-disabled:active .x-button-inner{transform:none}.x-button-initial-plain{color:var(--x-text);background-color:var(--x-background-a200);border-color:var(--x-border)}.x-button-initial-plain:hover{color:var(--x-primary);background-color:var(--x-background-a200);border-color:var(--x-primary)}.x-button-initial-plain:active{color:var(--x-primary-a100);background-color:var(--x-background-a200);border-color:var(--x-primary-a100)}.x-button-initial-plain:focus{color:var(--x-primary-a100);background-color:var(--x-background-a200);border-color:var(--x-primary-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-initial-plain.x-button-disabled{color:var(--x-text-400);cursor:not-allowed;background-image:none;background-color:var(--x-background-200);border-color:var(--x-border);box-shadow:none}.x-button-initial-plain.x-button-disabled:hover,.x-button-initial-plain.x-button-disabled:active,.x-button-initial-plain.x-button-disabled:focus{color:var(--x-text-400);background-color:var(--x-background-200);border-color:var(--x-border)}.x-button-initial-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-initial.x-button-activated{z-index:2;color:var(--x-primary);background-color:var(--x-background);border-color:var(--x-primary)}.x-button-primary{color:var(--x-white);background-color:var(--x-primary);border-color:var(--x-primary)}.x-button-primary:hover{color:var(--x-white);background-color:var(--x-primary-100);border-color:var(--x-primary-100)}.x-button-primary:active{color:var(--x-white);background-color:var(--x-primary);border-color:var(--x-primary)}.x-button-primary:focus{color:var(--x-white);background-color:var(--x-primary);border-color:var(--x-primary);box-shadow:var(--x-box-shadow-focus)}.x-button-primary.x-button-disabled{color:var(--x-primary-800);cursor:not-allowed;background-image:none;background-color:var(--x-primary-500);border-color:var(--x-primary-500);box-shadow:none}.x-button-primary.x-button-disabled:hover,.x-button-primary.x-button-disabled:active,.x-button-primary.x-button-disabled:focus{color:var(--x-primary-800);background-color:var(--x-primary-500);border-color:var(--x-primary-500)}.x-button-primary.x-button-disabled:active .x-button-inner{transform:none}.x-button-primary-plain{color:var(--x-primary);background-color:var(--x-primary-900);border-color:var(--x-primary-600)}.x-button-primary-plain:hover{color:var(--x-background-900);background-color:var(--x-primary);border-color:var(--x-primary)}.x-button-primary-plain:active{color:var(--x-background-900);background-color:var(--x-primary-a100);border-color:var(--x-primary-a100)}.x-button-primary-plain:focus{color:var(--x-background-900);background-color:var(--x-primary-a100);border-color:var(--x-primary-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-primary-plain.x-button-disabled{color:var(--x-primary-400);cursor:not-allowed;background-image:none;background-color:var(--x-primary-900);border-color:var(--x-primary-800);box-shadow:none}.x-button-primary-plain.x-button-disabled:hover,.x-button-primary-plain.x-button-disabled:active,.x-button-primary-plain.x-button-disabled:focus{color:var(--x-primary-400);background-color:var(--x-primary-900);border-color:var(--x-primary-800)}.x-button-primary-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-primary.x-button-activated{z-index:2;color:var(--x-white);background-color:var(--x-primary);border-color:var(--x-primary)}.x-button-success{color:var(--x-white);background-color:var(--x-success);border-color:var(--x-success)}.x-button-success:hover{color:var(--x-white);background-color:var(--x-success-100);border-color:var(--x-success-100)}.x-button-success:active{color:var(--x-white);background-color:var(--x-success);border-color:var(--x-success)}.x-button-success:focus{color:var(--x-white);background-color:var(--x-success);border-color:var(--x-success);box-shadow:var(--x-box-shadow-focus)}.x-button-success.x-button-disabled{color:var(--x-success-800);cursor:not-allowed;background-image:none;background-color:var(--x-success-500);border-color:var(--x-success-500);box-shadow:none}.x-button-success.x-button-disabled:hover,.x-button-success.x-button-disabled:active,.x-button-success.x-button-disabled:focus{color:var(--x-success-800);background-color:var(--x-success-500);border-color:var(--x-success-500)}.x-button-success.x-button-disabled:active .x-button-inner{transform:none}.x-button-success-plain{color:var(--x-success);background-color:var(--x-success-900);border-color:var(--x-success-600)}.x-button-success-plain:hover{color:var(--x-background-900);background-color:var(--x-success);border-color:var(--x-success)}.x-button-success-plain:active{color:var(--x-background-900);background-color:var(--x-success-a100);border-color:var(--x-success-a100)}.x-button-success-plain:focus{color:var(--x-background-900);background-color:var(--x-success-a100);border-color:var(--x-success-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-success-plain.x-button-disabled{color:var(--x-success-400);cursor:not-allowed;background-image:none;background-color:var(--x-success-900);border-color:var(--x-success-800);box-shadow:none}.x-button-success-plain.x-button-disabled:hover,.x-button-success-plain.x-button-disabled:active,.x-button-success-plain.x-button-disabled:focus{color:var(--x-success-400);background-color:var(--x-success-900);border-color:var(--x-success-800)}.x-button-success-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-success.x-button-activated{z-index:2;color:var(--x-white);background-color:var(--x-success);border-color:var(--x-success)}.x-button-warning{color:var(--x-white);background-color:var(--x-warning);border-color:var(--x-warning)}.x-button-warning:hover{color:var(--x-white);background-color:var(--x-warning-100);border-color:var(--x-warning-100)}.x-button-warning:active{color:var(--x-white);background-color:var(--x-warning);border-color:var(--x-warning)}.x-button-warning:focus{color:var(--x-white);background-color:var(--x-warning);border-color:var(--x-warning);box-shadow:var(--x-box-shadow-focus)}.x-button-warning.x-button-disabled{color:var(--x-warning-800);cursor:not-allowed;background-image:none;background-color:var(--x-warning-500);border-color:var(--x-warning-500);box-shadow:none}.x-button-warning.x-button-disabled:hover,.x-button-warning.x-button-disabled:active,.x-button-warning.x-button-disabled:focus{color:var(--x-warning-800);background-color:var(--x-warning-500);border-color:var(--x-warning-500)}.x-button-warning.x-button-disabled:active .x-button-inner{transform:none}.x-button-warning-plain{color:var(--x-warning);background-color:var(--x-warning-900);border-color:var(--x-warning-600)}.x-button-warning-plain:hover{color:var(--x-background-900);background-color:var(--x-warning);border-color:var(--x-warning)}.x-button-warning-plain:active{color:var(--x-background-900);background-color:var(--x-warning-a100);border-color:var(--x-warning-a100)}.x-button-warning-plain:focus{color:var(--x-background-900);background-color:var(--x-warning-a100);border-color:var(--x-warning-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-warning-plain.x-button-disabled{color:var(--x-warning-400);cursor:not-allowed;background-image:none;background-color:var(--x-warning-900);border-color:var(--x-warning-800);box-shadow:none}.x-button-warning-plain.x-button-disabled:hover,.x-button-warning-plain.x-button-disabled:active,.x-button-warning-plain.x-button-disabled:focus{color:var(--x-warning-400);background-color:var(--x-warning-900);border-color:var(--x-warning-800)}.x-button-warning-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-warning.x-button-activated{z-index:2;color:var(--x-white);background-color:var(--x-warning);border-color:var(--x-warning)}.x-button-danger{color:var(--x-white);background-color:var(--x-danger);border-color:var(--x-danger)}.x-button-danger:hover{color:var(--x-white);background-color:var(--x-danger-100);border-color:var(--x-danger-100)}.x-button-danger:active{color:var(--x-white);background-color:var(--x-danger);border-color:var(--x-danger)}.x-button-danger:focus{color:var(--x-white);background-color:var(--x-danger);border-color:var(--x-danger);box-shadow:var(--x-box-shadow-focus)}.x-button-danger.x-button-disabled{color:var(--x-danger-800);cursor:not-allowed;background-image:none;background-color:var(--x-danger-500);border-color:var(--x-danger-500);box-shadow:none}.x-button-danger.x-button-disabled:hover,.x-button-danger.x-button-disabled:active,.x-button-danger.x-button-disabled:focus{color:var(--x-danger-800);background-color:var(--x-danger-500);border-color:var(--x-danger-500)}.x-button-danger.x-button-disabled:active .x-button-inner{transform:none}.x-button-danger-plain{color:var(--x-danger);background-color:var(--x-danger-900);border-color:var(--x-danger-600)}.x-button-danger-plain:hover{color:var(--x-background-900);background-color:var(--x-danger);border-color:var(--x-danger)}.x-button-danger-plain:active{color:var(--x-background-900);background-color:var(--x-danger-a100);border-color:var(--x-danger-a100)}.x-button-danger-plain:focus{color:var(--x-background-900);background-color:var(--x-danger-a100);border-color:var(--x-danger-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-danger-plain.x-button-disabled{color:var(--x-danger-400);cursor:not-allowed;background-image:none;background-color:var(--x-danger-900);border-color:var(--x-danger-800);box-shadow:none}.x-button-danger-plain.x-button-disabled:hover,.x-button-danger-plain.x-button-disabled:active,.x-button-danger-plain.x-button-disabled:focus{color:var(--x-danger-400);background-color:var(--x-danger-900);border-color:var(--x-danger-800)}.x-button-danger-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-danger.x-button-activated{z-index:2;color:var(--x-white);background-color:var(--x-danger);border-color:var(--x-danger)}.x-button-info{color:var(--x-white);background-color:var(--x-info);border-color:var(--x-info)}.x-button-info:hover{color:var(--x-white);background-color:var(--x-info-100);border-color:var(--x-info-100)}.x-button-info:active{color:var(--x-white);background-color:var(--x-info);border-color:var(--x-info)}.x-button-info:focus{color:var(--x-white);background-color:var(--x-info);border-color:var(--x-info);box-shadow:var(--x-box-shadow-focus)}.x-button-info.x-button-disabled{color:var(--x-info-800);cursor:not-allowed;background-image:none;background-color:var(--x-info-500);border-color:var(--x-info-500);box-shadow:none}.x-button-info.x-button-disabled:hover,.x-button-info.x-button-disabled:active,.x-button-info.x-button-disabled:focus{color:var(--x-info-800);background-color:var(--x-info-500);border-color:var(--x-info-500)}.x-button-info.x-button-disabled:active .x-button-inner{transform:none}.x-button-info-plain{color:var(--x-info);background-color:var(--x-info-900);border-color:var(--x-info-600)}.x-button-info-plain:hover{color:var(--x-background-900);background-color:var(--x-info);border-color:var(--x-info)}.x-button-info-plain:active{color:var(--x-background-900);background-color:var(--x-info-a100);border-color:var(--x-info-a100)}.x-button-info-plain:focus{color:var(--x-background-900);background-color:var(--x-info-a100);border-color:var(--x-info-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-info-plain.x-button-disabled{color:var(--x-info-400);cursor:not-allowed;background-image:none;background-color:var(--x-info-900);border-color:var(--x-info-800);box-shadow:none}.x-button-info-plain.x-button-disabled:hover,.x-button-info-plain.x-button-disabled:active,.x-button-info-plain.x-button-disabled:focus{color:var(--x-info-400);background-color:var(--x-info-900);border-color:var(--x-info-800)}.x-button-info-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-info.x-button-activated{z-index:2;color:var(--x-white);background-color:var(--x-info);border-color:var(--x-info)}\n"], dependencies: [{ kind: "directive", type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i4.XIconComponent, selector: "x-icon" }, { kind: "directive", type: i5.XRippleDirective, selector: "[x-ripple]" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
222
231
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.0.2", ngImport: i0, type: XButtonComponent, decorators: [{
|
|
223
232
|
type: Component,
|
|
224
|
-
args: [{ selector: `${XButtonPrefix}`, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<button\r\n class=\"x-button\"\r\n [tabindex]=\"tabindex\"\r\n [ngClass]=\"classMap\"\r\n [class.x-button-only-icon]=\"onlyIcon\"\r\n [class.x-button-activated]=\"activated\"\r\n [class.x-button-disabled]=\"disabled\"\r\n [class.x-button-round]=\"round\"\r\n [class.x-button-circle]=\"circle\"\r\n [class.x-button-icon]=\"icon && !content.innerHTML.trim()\"\r\n [class.x-button-closable]=\"closable\"\r\n [title]=\"title\"\r\n x-ripple\r\n [type]=\"type\"\r\n [disabled]=\"disabled\"\r\n [attr.type]=\"attrType\"\r\n>\r\n <x-icon *ngIf=\"icon && !loading\" [type]=\"icon\"></x-icon>\r\n <x-icon *ngIf=\"loading\" type=\"fto-loader\" [spin]=\"loading\"></x-icon>\r\n <span #content><ng-content></ng-content></span>\r\n</button>\r\n\r\n<!-- \u63D0\u524D\u52A0\u8F7D loading \u7684\u56FE\u6807-->\r\n<x-icon *ngIf=\"loading\" [style.display]=\"'none'\" type=\"fto-loader\"></x-icon>\r\n", styles: ["x-button{display:inline-flex;line-height:initial}.x-button{margin:0;padding:0;border:var(--x-border-width) solid;border-radius:var(--x-border-radius);flex:1;display:inline-flex;align-items:center;justify-content:center;font-size:var(--x-font-size-small);text-align:center;background-clip:border-box;cursor:pointer;-webkit-user-select:none;user-select:none;white-space:nowrap;transition:color var(--x-animation-duration-base) ease-in-out,background-color var(--x-animation-duration-base) ease-in-out,border var(--x-animation-duration-base) ease-in-out}.x-button:focus{outline:none}.x-button>.x-icon{font-size:.925rem}.x-button.x-direction-column{flex-direction:column}.x-button.x-direction-column-reverse{flex-direction:column-reverse}.x-button.x-direction-row{flex-direction:row}.x-button.x-direction-row-reverse{flex-direction:row-reverse}.x-button.x-direction-row>.x-icon{margin-right:.25rem;margin-left:-.25rem}.x-button.x-direction-row-reverse>.x-icon{margin-right:-.25rem;margin-left:.25rem}.x-button-icon.x-direction-row>.x-icon,.x-button-icon.x-direction-row-reverse>.x-icon{margin-right:0;margin-left:0}.x-button-disabled{transform:none!important}.x-button-round{border-radius:5rem}.x-button-circle{border-radius:50%;padding:0;width:1.675rem}.x-button-only-icon,.x-button-only-icon.x-button-initial,.x-button-text{border:none;background-color:transparent;box-shadow:none}.x-button-only-icon:focus,.x-button-only-icon:hover,.x-button-only-icon:active,.x-button-only-icon.x-button-initial:focus,.x-button-only-icon.x-button-initial:hover,.x-button-only-icon.x-button-initial:active,.x-button-text:focus,.x-button-text:hover,.x-button-text:active{color:var(--x-primary);background-color:#0000001a;border-color:transparent}.x-button-closable{color:var(--x-text-400)}.x-button-closable:hover{color:var(--x-text-300)}.x-button-disabled.x-button-activated.x-button-initial{color:var(--x-primary-700);cursor:not-allowed;background-image:none;background-color:var(--x-background);border-color:var(--x-primary-700);box-shadow:none}.x-button-disabled.x-button-activated.x-button-initial:hover,.x-button-disabled.x-button-activated.x-button-initial:active,.x-button-disabled.x-button-activated.x-button-initial:focus{color:var(--x-primary-700);background-color:var(--x-background);border-color:var(--x-primary-700)}.x-button-disabled.x-button-activated.x-button-initial:active .x-button-inner{transform:none}.x-button-disabled.x-button-activated.x-button-initial:hover,.x-button-disabled.x-button-activated.x-button-initial:active{color:var(--x-primary-700);cursor:not-allowed;background-image:none;background-color:var(--x-background);border-color:var(--x-primary-700);box-shadow:none}.x-button-disabled.x-button-activated.x-button-initial:hover:hover,.x-button-disabled.x-button-activated.x-button-initial:hover:active,.x-button-disabled.x-button-activated.x-button-initial:hover:focus,.x-button-disabled.x-button-activated.x-button-initial:active:hover,.x-button-disabled.x-button-activated.x-button-initial:active:active,.x-button-disabled.x-button-activated.x-button-initial:active:focus{color:var(--x-primary-700);background-color:var(--x-background);border-color:var(--x-primary-700)}.x-button-disabled.x-button-activated.x-button-initial:hover:active .x-button-inner,.x-button-disabled.x-button-activated.x-button-initial:active:active .x-button-inner{transform:none}.x-button-disabled.x-button-text,.x-button-disabled.x-button-only-icon{color:var(--x-text-400);cursor:not-allowed;background-image:none;background-color:transparent;border-color:transparent;box-shadow:none}.x-button-disabled.x-button-text:hover,.x-button-disabled.x-button-text:active,.x-button-disabled.x-button-text:focus,.x-button-disabled.x-button-only-icon:hover,.x-button-disabled.x-button-only-icon:active,.x-button-disabled.x-button-only-icon:focus{color:var(--x-text-400);background-color:transparent;border-color:transparent}.x-button-disabled.x-button-text:active .x-button-inner,.x-button-disabled.x-button-only-icon:active .x-button-inner{transform:none}.x-button-disabled.x-button-text:hover,.x-button-disabled.x-button-text:active,.x-button-disabled.x-button-only-icon:hover,.x-button-disabled.x-button-only-icon:active{color:var(--x-text-400);cursor:not-allowed;background-image:none;background-color:transparent;border-color:transparent;box-shadow:none}.x-button-disabled.x-button-text:hover:hover,.x-button-disabled.x-button-text:hover:active,.x-button-disabled.x-button-text:hover:focus,.x-button-disabled.x-button-text:active:hover,.x-button-disabled.x-button-text:active:active,.x-button-disabled.x-button-text:active:focus,.x-button-disabled.x-button-only-icon:hover:hover,.x-button-disabled.x-button-only-icon:hover:active,.x-button-disabled.x-button-only-icon:hover:focus,.x-button-disabled.x-button-only-icon:active:hover,.x-button-disabled.x-button-only-icon:active:active,.x-button-disabled.x-button-only-icon:active:focus{color:var(--x-text-400);background-color:transparent;border-color:transparent}.x-button-disabled.x-button-text:hover:active .x-button-inner,.x-button-disabled.x-button-text:active:active .x-button-inner,.x-button-disabled.x-button-only-icon:hover:active .x-button-inner,.x-button-disabled.x-button-only-icon:active:active .x-button-inner{transform:none}.x-button.x-size-big{height:var(--x-height-big);line-height:var(--x-height-big);padding:0 var(--x-padding-big)}.x-button.x-size-large{height:var(--x-height-large);line-height:var(--x-height-large);padding:0 var(--x-padding-large)}.x-button.x-size-medium{height:var(--x-height-medium);line-height:var(--x-height-medium);padding:0 var(--x-padding-medium)}.x-button.x-size-small{height:var(--x-height-small);line-height:var(--x-height-small);padding:0 var(--x-padding-small)}.x-button.x-size-mini{height:var(--x-height-mini);line-height:var(--x-height-mini);padding:0 var(--x-padding-mini)}.x-button-initial{color:var(--x-text);background-color:var(--x-background);border-color:var(--x-border)}.x-button-initial:hover,.x-button-initial:active{color:var(--x-primary);background-color:var(--x-background);border-color:var(--x-primary)}.x-button-initial:focus{color:var(--x-primary);background-color:var(--x-background);border-color:var(--x-primary);box-shadow:var(--x-box-shadow-focus)}.x-button-initial.x-button-disabled{color:var(--x-text-400);cursor:not-allowed;background-image:none;background-color:var(--x-background-200);border-color:var(--x-border);box-shadow:none}.x-button-initial.x-button-disabled:hover,.x-button-initial.x-button-disabled:active,.x-button-initial.x-button-disabled:focus{color:var(--x-text-400);background-color:var(--x-background-200);border-color:var(--x-border)}.x-button-initial.x-button-disabled:active .x-button-inner{transform:none}.x-button-initial-plain{color:var(--x-text);background-color:var(--x-background-a200);border-color:var(--x-border)}.x-button-initial-plain:hover{color:var(--x-primary);background-color:var(--x-background-a200);border-color:var(--x-primary)}.x-button-initial-plain:active{color:var(--x-primary-a100);background-color:var(--x-background-a200);border-color:var(--x-primary-a100)}.x-button-initial-plain:focus{color:var(--x-primary-a100);background-color:var(--x-background-a200);border-color:var(--x-primary-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-initial-plain.x-button-disabled{color:var(--x-text-400);cursor:not-allowed;background-image:none;background-color:var(--x-background-200);border-color:var(--x-border);box-shadow:none}.x-button-initial-plain.x-button-disabled:hover,.x-button-initial-plain.x-button-disabled:active,.x-button-initial-plain.x-button-disabled:focus{color:var(--x-text-400);background-color:var(--x-background-200);border-color:var(--x-border)}.x-button-initial-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-initial.x-button-activated{z-index:2;color:var(--x-primary);background-color:var(--x-background);border-color:var(--x-primary)}.x-button-primary{color:var(--x-white);background-color:var(--x-primary);border-color:var(--x-primary)}.x-button-primary:hover{color:var(--x-white);background-color:var(--x-primary-100);border-color:var(--x-primary-100)}.x-button-primary:active{color:var(--x-white);background-color:var(--x-primary);border-color:var(--x-primary)}.x-button-primary:focus{color:var(--x-white);background-color:var(--x-primary);border-color:var(--x-primary);box-shadow:var(--x-box-shadow-focus)}.x-button-primary.x-button-disabled{color:var(--x-primary-800);cursor:not-allowed;background-image:none;background-color:var(--x-primary-500);border-color:var(--x-primary-500);box-shadow:none}.x-button-primary.x-button-disabled:hover,.x-button-primary.x-button-disabled:active,.x-button-primary.x-button-disabled:focus{color:var(--x-primary-800);background-color:var(--x-primary-500);border-color:var(--x-primary-500)}.x-button-primary.x-button-disabled:active .x-button-inner{transform:none}.x-button-primary-plain{color:var(--x-primary);background-color:var(--x-primary-900);border-color:var(--x-primary-600)}.x-button-primary-plain:hover{color:var(--x-background-900);background-color:var(--x-primary);border-color:var(--x-primary)}.x-button-primary-plain:active{color:var(--x-background-900);background-color:var(--x-primary-a100);border-color:var(--x-primary-a100)}.x-button-primary-plain:focus{color:var(--x-background-900);background-color:var(--x-primary-a100);border-color:var(--x-primary-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-primary-plain.x-button-disabled{color:var(--x-primary-400);cursor:not-allowed;background-image:none;background-color:var(--x-primary-900);border-color:var(--x-primary-800);box-shadow:none}.x-button-primary-plain.x-button-disabled:hover,.x-button-primary-plain.x-button-disabled:active,.x-button-primary-plain.x-button-disabled:focus{color:var(--x-primary-400);background-color:var(--x-primary-900);border-color:var(--x-primary-800)}.x-button-primary-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-primary.x-button-activated{z-index:2;color:var(--x-white);background-color:var(--x-primary);border-color:var(--x-primary)}.x-button-success{color:var(--x-white);background-color:var(--x-success);border-color:var(--x-success)}.x-button-success:hover{color:var(--x-white);background-color:var(--x-success-100);border-color:var(--x-success-100)}.x-button-success:active{color:var(--x-white);background-color:var(--x-success);border-color:var(--x-success)}.x-button-success:focus{color:var(--x-white);background-color:var(--x-success);border-color:var(--x-success);box-shadow:var(--x-box-shadow-focus)}.x-button-success.x-button-disabled{color:var(--x-success-800);cursor:not-allowed;background-image:none;background-color:var(--x-success-500);border-color:var(--x-success-500);box-shadow:none}.x-button-success.x-button-disabled:hover,.x-button-success.x-button-disabled:active,.x-button-success.x-button-disabled:focus{color:var(--x-success-800);background-color:var(--x-success-500);border-color:var(--x-success-500)}.x-button-success.x-button-disabled:active .x-button-inner{transform:none}.x-button-success-plain{color:var(--x-success);background-color:var(--x-success-900);border-color:var(--x-success-600)}.x-button-success-plain:hover{color:var(--x-background-900);background-color:var(--x-success);border-color:var(--x-success)}.x-button-success-plain:active{color:var(--x-background-900);background-color:var(--x-success-a100);border-color:var(--x-success-a100)}.x-button-success-plain:focus{color:var(--x-background-900);background-color:var(--x-success-a100);border-color:var(--x-success-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-success-plain.x-button-disabled{color:var(--x-success-400);cursor:not-allowed;background-image:none;background-color:var(--x-success-900);border-color:var(--x-success-800);box-shadow:none}.x-button-success-plain.x-button-disabled:hover,.x-button-success-plain.x-button-disabled:active,.x-button-success-plain.x-button-disabled:focus{color:var(--x-success-400);background-color:var(--x-success-900);border-color:var(--x-success-800)}.x-button-success-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-success.x-button-activated{z-index:2;color:var(--x-white);background-color:var(--x-success);border-color:var(--x-success)}.x-button-warning{color:var(--x-white);background-color:var(--x-warning);border-color:var(--x-warning)}.x-button-warning:hover{color:var(--x-white);background-color:var(--x-warning-100);border-color:var(--x-warning-100)}.x-button-warning:active{color:var(--x-white);background-color:var(--x-warning);border-color:var(--x-warning)}.x-button-warning:focus{color:var(--x-white);background-color:var(--x-warning);border-color:var(--x-warning);box-shadow:var(--x-box-shadow-focus)}.x-button-warning.x-button-disabled{color:var(--x-warning-800);cursor:not-allowed;background-image:none;background-color:var(--x-warning-500);border-color:var(--x-warning-500);box-shadow:none}.x-button-warning.x-button-disabled:hover,.x-button-warning.x-button-disabled:active,.x-button-warning.x-button-disabled:focus{color:var(--x-warning-800);background-color:var(--x-warning-500);border-color:var(--x-warning-500)}.x-button-warning.x-button-disabled:active .x-button-inner{transform:none}.x-button-warning-plain{color:var(--x-warning);background-color:var(--x-warning-900);border-color:var(--x-warning-600)}.x-button-warning-plain:hover{color:var(--x-background-900);background-color:var(--x-warning);border-color:var(--x-warning)}.x-button-warning-plain:active{color:var(--x-background-900);background-color:var(--x-warning-a100);border-color:var(--x-warning-a100)}.x-button-warning-plain:focus{color:var(--x-background-900);background-color:var(--x-warning-a100);border-color:var(--x-warning-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-warning-plain.x-button-disabled{color:var(--x-warning-400);cursor:not-allowed;background-image:none;background-color:var(--x-warning-900);border-color:var(--x-warning-800);box-shadow:none}.x-button-warning-plain.x-button-disabled:hover,.x-button-warning-plain.x-button-disabled:active,.x-button-warning-plain.x-button-disabled:focus{color:var(--x-warning-400);background-color:var(--x-warning-900);border-color:var(--x-warning-800)}.x-button-warning-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-warning.x-button-activated{z-index:2;color:var(--x-white);background-color:var(--x-warning);border-color:var(--x-warning)}.x-button-danger{color:var(--x-white);background-color:var(--x-danger);border-color:var(--x-danger)}.x-button-danger:hover{color:var(--x-white);background-color:var(--x-danger-100);border-color:var(--x-danger-100)}.x-button-danger:active{color:var(--x-white);background-color:var(--x-danger);border-color:var(--x-danger)}.x-button-danger:focus{color:var(--x-white);background-color:var(--x-danger);border-color:var(--x-danger);box-shadow:var(--x-box-shadow-focus)}.x-button-danger.x-button-disabled{color:var(--x-danger-800);cursor:not-allowed;background-image:none;background-color:var(--x-danger-500);border-color:var(--x-danger-500);box-shadow:none}.x-button-danger.x-button-disabled:hover,.x-button-danger.x-button-disabled:active,.x-button-danger.x-button-disabled:focus{color:var(--x-danger-800);background-color:var(--x-danger-500);border-color:var(--x-danger-500)}.x-button-danger.x-button-disabled:active .x-button-inner{transform:none}.x-button-danger-plain{color:var(--x-danger);background-color:var(--x-danger-900);border-color:var(--x-danger-600)}.x-button-danger-plain:hover{color:var(--x-background-900);background-color:var(--x-danger);border-color:var(--x-danger)}.x-button-danger-plain:active{color:var(--x-background-900);background-color:var(--x-danger-a100);border-color:var(--x-danger-a100)}.x-button-danger-plain:focus{color:var(--x-background-900);background-color:var(--x-danger-a100);border-color:var(--x-danger-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-danger-plain.x-button-disabled{color:var(--x-danger-400);cursor:not-allowed;background-image:none;background-color:var(--x-danger-900);border-color:var(--x-danger-800);box-shadow:none}.x-button-danger-plain.x-button-disabled:hover,.x-button-danger-plain.x-button-disabled:active,.x-button-danger-plain.x-button-disabled:focus{color:var(--x-danger-400);background-color:var(--x-danger-900);border-color:var(--x-danger-800)}.x-button-danger-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-danger.x-button-activated{z-index:2;color:var(--x-white);background-color:var(--x-danger);border-color:var(--x-danger)}.x-button-info{color:var(--x-white);background-color:var(--x-info);border-color:var(--x-info)}.x-button-info:hover{color:var(--x-white);background-color:var(--x-info-100);border-color:var(--x-info-100)}.x-button-info:active{color:var(--x-white);background-color:var(--x-info);border-color:var(--x-info)}.x-button-info:focus{color:var(--x-white);background-color:var(--x-info);border-color:var(--x-info);box-shadow:var(--x-box-shadow-focus)}.x-button-info.x-button-disabled{color:var(--x-info-800);cursor:not-allowed;background-image:none;background-color:var(--x-info-500);border-color:var(--x-info-500);box-shadow:none}.x-button-info.x-button-disabled:hover,.x-button-info.x-button-disabled:active,.x-button-info.x-button-disabled:focus{color:var(--x-info-800);background-color:var(--x-info-500);border-color:var(--x-info-500)}.x-button-info.x-button-disabled:active .x-button-inner{transform:none}.x-button-info-plain{color:var(--x-info);background-color:var(--x-info-900);border-color:var(--x-info-600)}.x-button-info-plain:hover{color:var(--x-background-900);background-color:var(--x-info);border-color:var(--x-info)}.x-button-info-plain:active{color:var(--x-background-900);background-color:var(--x-info-a100);border-color:var(--x-info-a100)}.x-button-info-plain:focus{color:var(--x-background-900);background-color:var(--x-info-a100);border-color:var(--x-info-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-info-plain.x-button-disabled{color:var(--x-info-400);cursor:not-allowed;background-image:none;background-color:var(--x-info-900);border-color:var(--x-info-800);box-shadow:none}.x-button-info-plain.x-button-disabled:hover,.x-button-info-plain.x-button-disabled:active,.x-button-info-plain.x-button-disabled:focus{color:var(--x-info-400);background-color:var(--x-info-900);border-color:var(--x-info-800)}.x-button-info-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-info.x-button-activated{z-index:2;color:var(--x-white);background-color:var(--x-info);border-color:var(--x-info)}\n"] }]
|
|
233
|
+
args: [{ selector: `${XButtonPrefix}`, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<button\r\n class=\"x-button\"\r\n [tabindex]=\"tabindex\"\r\n [ngClass]=\"classMap\"\r\n [class.x-button-only-icon]=\"onlyIcon\"\r\n [class.x-button-activated]=\"activated\"\r\n [class.x-button-disabled]=\"disabled\"\r\n [class.x-button-round]=\"round\"\r\n [class.x-button-circle]=\"circle\"\r\n [class.x-button-icon]=\"icon && !content.innerHTML.trim()\"\r\n [class.x-button-closable]=\"closable\"\r\n [class.x-button-transition]=\"transition\"\r\n [title]=\"title\"\r\n x-ripple\r\n [type]=\"type\"\r\n [disabled]=\"disabled\"\r\n [attr.type]=\"attrType\"\r\n>\r\n <x-icon *ngIf=\"icon && !loading\" [type]=\"icon\"></x-icon>\r\n <x-icon *ngIf=\"loading\" type=\"fto-loader\" [spin]=\"loading\"></x-icon>\r\n <span #content><ng-content></ng-content></span>\r\n</button>\r\n\r\n<!-- \u63D0\u524D\u52A0\u8F7D loading \u7684\u56FE\u6807-->\r\n<x-icon *ngIf=\"loading\" [style.display]=\"'none'\" type=\"fto-loader\"></x-icon>\r\n", styles: ["x-button{display:inline-flex;line-height:initial}.x-button{margin:0;padding:0;border:var(--x-border-width) solid;border-radius:var(--x-border-radius);flex:1;display:inline-flex;align-items:center;justify-content:center;font-size:var(--x-font-size-small);text-align:center;background-clip:border-box;cursor:pointer;-webkit-user-select:none;user-select:none;white-space:nowrap;touch-action:manipulation;will-change:color,background-color,border}.x-button:focus{outline:none}.x-button>.x-icon{font-size:.925rem}.x-button.x-direction-column{flex-direction:column}.x-button.x-direction-column-reverse{flex-direction:column-reverse}.x-button.x-direction-row{flex-direction:row}.x-button.x-direction-row-reverse{flex-direction:row-reverse}.x-button.x-direction-row>.x-icon{margin-right:.25rem;margin-left:-.25rem}.x-button.x-direction-row-reverse>.x-icon{margin-right:-.25rem;margin-left:.25rem}.x-button-icon.x-direction-row>.x-icon,.x-button-icon.x-direction-row-reverse>.x-icon{margin-right:0;margin-left:0}.x-button-transition{transition:color var(--x-animation-duration-base) ease-in-out,background-color var(--x-animation-duration-base) ease-in-out,border var(--x-animation-duration-base) ease-in-out}.x-button-disabled{transform:none!important}.x-button-round{border-radius:5rem}.x-button-circle{border-radius:50%;padding:0;width:1.675rem}.x-button-only-icon,.x-button-only-icon.x-button-initial,.x-button-text{border:none;background-color:transparent;box-shadow:none}.x-button-only-icon:focus,.x-button-only-icon:hover,.x-button-only-icon:active,.x-button-only-icon.x-button-initial:focus,.x-button-only-icon.x-button-initial:hover,.x-button-only-icon.x-button-initial:active,.x-button-text:focus,.x-button-text:hover,.x-button-text:active{color:var(--x-primary);background-color:#0000001a;border-color:transparent}.x-button-closable{color:var(--x-text-400)}.x-button-closable:hover{color:var(--x-text-300)}.x-button-disabled.x-button-activated.x-button-initial{color:var(--x-primary-700);cursor:not-allowed;background-image:none;background-color:var(--x-background);border-color:var(--x-primary-700);box-shadow:none}.x-button-disabled.x-button-activated.x-button-initial:hover,.x-button-disabled.x-button-activated.x-button-initial:active,.x-button-disabled.x-button-activated.x-button-initial:focus{color:var(--x-primary-700);background-color:var(--x-background);border-color:var(--x-primary-700)}.x-button-disabled.x-button-activated.x-button-initial:active .x-button-inner{transform:none}.x-button-disabled.x-button-activated.x-button-initial:hover,.x-button-disabled.x-button-activated.x-button-initial:active{color:var(--x-primary-700);cursor:not-allowed;background-image:none;background-color:var(--x-background);border-color:var(--x-primary-700);box-shadow:none}.x-button-disabled.x-button-activated.x-button-initial:hover:hover,.x-button-disabled.x-button-activated.x-button-initial:hover:active,.x-button-disabled.x-button-activated.x-button-initial:hover:focus,.x-button-disabled.x-button-activated.x-button-initial:active:hover,.x-button-disabled.x-button-activated.x-button-initial:active:active,.x-button-disabled.x-button-activated.x-button-initial:active:focus{color:var(--x-primary-700);background-color:var(--x-background);border-color:var(--x-primary-700)}.x-button-disabled.x-button-activated.x-button-initial:hover:active .x-button-inner,.x-button-disabled.x-button-activated.x-button-initial:active:active .x-button-inner{transform:none}.x-button-disabled.x-button-text,.x-button-disabled.x-button-only-icon{color:var(--x-text-400);cursor:not-allowed;background-image:none;background-color:transparent;border-color:transparent;box-shadow:none}.x-button-disabled.x-button-text:hover,.x-button-disabled.x-button-text:active,.x-button-disabled.x-button-text:focus,.x-button-disabled.x-button-only-icon:hover,.x-button-disabled.x-button-only-icon:active,.x-button-disabled.x-button-only-icon:focus{color:var(--x-text-400);background-color:transparent;border-color:transparent}.x-button-disabled.x-button-text:active .x-button-inner,.x-button-disabled.x-button-only-icon:active .x-button-inner{transform:none}.x-button-disabled.x-button-text:hover,.x-button-disabled.x-button-text:active,.x-button-disabled.x-button-only-icon:hover,.x-button-disabled.x-button-only-icon:active{color:var(--x-text-400);cursor:not-allowed;background-image:none;background-color:transparent;border-color:transparent;box-shadow:none}.x-button-disabled.x-button-text:hover:hover,.x-button-disabled.x-button-text:hover:active,.x-button-disabled.x-button-text:hover:focus,.x-button-disabled.x-button-text:active:hover,.x-button-disabled.x-button-text:active:active,.x-button-disabled.x-button-text:active:focus,.x-button-disabled.x-button-only-icon:hover:hover,.x-button-disabled.x-button-only-icon:hover:active,.x-button-disabled.x-button-only-icon:hover:focus,.x-button-disabled.x-button-only-icon:active:hover,.x-button-disabled.x-button-only-icon:active:active,.x-button-disabled.x-button-only-icon:active:focus{color:var(--x-text-400);background-color:transparent;border-color:transparent}.x-button-disabled.x-button-text:hover:active .x-button-inner,.x-button-disabled.x-button-text:active:active .x-button-inner,.x-button-disabled.x-button-only-icon:hover:active .x-button-inner,.x-button-disabled.x-button-only-icon:active:active .x-button-inner{transform:none}.x-button.x-size-big{height:var(--x-height-big);line-height:var(--x-height-big);padding:0 var(--x-padding-big)}.x-button.x-size-large{height:var(--x-height-large);line-height:var(--x-height-large);padding:0 var(--x-padding-large)}.x-button.x-size-medium{height:var(--x-height-medium);line-height:var(--x-height-medium);padding:0 var(--x-padding-medium)}.x-button.x-size-small{height:var(--x-height-small);line-height:var(--x-height-small);padding:0 var(--x-padding-small)}.x-button.x-size-mini{height:var(--x-height-mini);line-height:var(--x-height-mini);padding:0 var(--x-padding-mini)}.x-button-initial{color:var(--x-text);background-color:var(--x-background);border-color:var(--x-border)}.x-button-initial:hover,.x-button-initial:active{color:var(--x-primary);background-color:var(--x-background);border-color:var(--x-primary)}.x-button-initial:focus{color:var(--x-primary);background-color:var(--x-background);border-color:var(--x-primary);box-shadow:var(--x-box-shadow-focus)}.x-button-initial.x-button-disabled{color:var(--x-text-400);cursor:not-allowed;background-image:none;background-color:var(--x-background-200);border-color:var(--x-border);box-shadow:none}.x-button-initial.x-button-disabled:hover,.x-button-initial.x-button-disabled:active,.x-button-initial.x-button-disabled:focus{color:var(--x-text-400);background-color:var(--x-background-200);border-color:var(--x-border)}.x-button-initial.x-button-disabled:active .x-button-inner{transform:none}.x-button-initial-plain{color:var(--x-text);background-color:var(--x-background-a200);border-color:var(--x-border)}.x-button-initial-plain:hover{color:var(--x-primary);background-color:var(--x-background-a200);border-color:var(--x-primary)}.x-button-initial-plain:active{color:var(--x-primary-a100);background-color:var(--x-background-a200);border-color:var(--x-primary-a100)}.x-button-initial-plain:focus{color:var(--x-primary-a100);background-color:var(--x-background-a200);border-color:var(--x-primary-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-initial-plain.x-button-disabled{color:var(--x-text-400);cursor:not-allowed;background-image:none;background-color:var(--x-background-200);border-color:var(--x-border);box-shadow:none}.x-button-initial-plain.x-button-disabled:hover,.x-button-initial-plain.x-button-disabled:active,.x-button-initial-plain.x-button-disabled:focus{color:var(--x-text-400);background-color:var(--x-background-200);border-color:var(--x-border)}.x-button-initial-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-initial.x-button-activated{z-index:2;color:var(--x-primary);background-color:var(--x-background);border-color:var(--x-primary)}.x-button-primary{color:var(--x-white);background-color:var(--x-primary);border-color:var(--x-primary)}.x-button-primary:hover{color:var(--x-white);background-color:var(--x-primary-100);border-color:var(--x-primary-100)}.x-button-primary:active{color:var(--x-white);background-color:var(--x-primary);border-color:var(--x-primary)}.x-button-primary:focus{color:var(--x-white);background-color:var(--x-primary);border-color:var(--x-primary);box-shadow:var(--x-box-shadow-focus)}.x-button-primary.x-button-disabled{color:var(--x-primary-800);cursor:not-allowed;background-image:none;background-color:var(--x-primary-500);border-color:var(--x-primary-500);box-shadow:none}.x-button-primary.x-button-disabled:hover,.x-button-primary.x-button-disabled:active,.x-button-primary.x-button-disabled:focus{color:var(--x-primary-800);background-color:var(--x-primary-500);border-color:var(--x-primary-500)}.x-button-primary.x-button-disabled:active .x-button-inner{transform:none}.x-button-primary-plain{color:var(--x-primary);background-color:var(--x-primary-900);border-color:var(--x-primary-600)}.x-button-primary-plain:hover{color:var(--x-background-900);background-color:var(--x-primary);border-color:var(--x-primary)}.x-button-primary-plain:active{color:var(--x-background-900);background-color:var(--x-primary-a100);border-color:var(--x-primary-a100)}.x-button-primary-plain:focus{color:var(--x-background-900);background-color:var(--x-primary-a100);border-color:var(--x-primary-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-primary-plain.x-button-disabled{color:var(--x-primary-400);cursor:not-allowed;background-image:none;background-color:var(--x-primary-900);border-color:var(--x-primary-800);box-shadow:none}.x-button-primary-plain.x-button-disabled:hover,.x-button-primary-plain.x-button-disabled:active,.x-button-primary-plain.x-button-disabled:focus{color:var(--x-primary-400);background-color:var(--x-primary-900);border-color:var(--x-primary-800)}.x-button-primary-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-primary.x-button-activated{z-index:2;color:var(--x-white);background-color:var(--x-primary);border-color:var(--x-primary)}.x-button-success{color:var(--x-white);background-color:var(--x-success);border-color:var(--x-success)}.x-button-success:hover{color:var(--x-white);background-color:var(--x-success-100);border-color:var(--x-success-100)}.x-button-success:active{color:var(--x-white);background-color:var(--x-success);border-color:var(--x-success)}.x-button-success:focus{color:var(--x-white);background-color:var(--x-success);border-color:var(--x-success);box-shadow:var(--x-box-shadow-focus)}.x-button-success.x-button-disabled{color:var(--x-success-800);cursor:not-allowed;background-image:none;background-color:var(--x-success-500);border-color:var(--x-success-500);box-shadow:none}.x-button-success.x-button-disabled:hover,.x-button-success.x-button-disabled:active,.x-button-success.x-button-disabled:focus{color:var(--x-success-800);background-color:var(--x-success-500);border-color:var(--x-success-500)}.x-button-success.x-button-disabled:active .x-button-inner{transform:none}.x-button-success-plain{color:var(--x-success);background-color:var(--x-success-900);border-color:var(--x-success-600)}.x-button-success-plain:hover{color:var(--x-background-900);background-color:var(--x-success);border-color:var(--x-success)}.x-button-success-plain:active{color:var(--x-background-900);background-color:var(--x-success-a100);border-color:var(--x-success-a100)}.x-button-success-plain:focus{color:var(--x-background-900);background-color:var(--x-success-a100);border-color:var(--x-success-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-success-plain.x-button-disabled{color:var(--x-success-400);cursor:not-allowed;background-image:none;background-color:var(--x-success-900);border-color:var(--x-success-800);box-shadow:none}.x-button-success-plain.x-button-disabled:hover,.x-button-success-plain.x-button-disabled:active,.x-button-success-plain.x-button-disabled:focus{color:var(--x-success-400);background-color:var(--x-success-900);border-color:var(--x-success-800)}.x-button-success-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-success.x-button-activated{z-index:2;color:var(--x-white);background-color:var(--x-success);border-color:var(--x-success)}.x-button-warning{color:var(--x-white);background-color:var(--x-warning);border-color:var(--x-warning)}.x-button-warning:hover{color:var(--x-white);background-color:var(--x-warning-100);border-color:var(--x-warning-100)}.x-button-warning:active{color:var(--x-white);background-color:var(--x-warning);border-color:var(--x-warning)}.x-button-warning:focus{color:var(--x-white);background-color:var(--x-warning);border-color:var(--x-warning);box-shadow:var(--x-box-shadow-focus)}.x-button-warning.x-button-disabled{color:var(--x-warning-800);cursor:not-allowed;background-image:none;background-color:var(--x-warning-500);border-color:var(--x-warning-500);box-shadow:none}.x-button-warning.x-button-disabled:hover,.x-button-warning.x-button-disabled:active,.x-button-warning.x-button-disabled:focus{color:var(--x-warning-800);background-color:var(--x-warning-500);border-color:var(--x-warning-500)}.x-button-warning.x-button-disabled:active .x-button-inner{transform:none}.x-button-warning-plain{color:var(--x-warning);background-color:var(--x-warning-900);border-color:var(--x-warning-600)}.x-button-warning-plain:hover{color:var(--x-background-900);background-color:var(--x-warning);border-color:var(--x-warning)}.x-button-warning-plain:active{color:var(--x-background-900);background-color:var(--x-warning-a100);border-color:var(--x-warning-a100)}.x-button-warning-plain:focus{color:var(--x-background-900);background-color:var(--x-warning-a100);border-color:var(--x-warning-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-warning-plain.x-button-disabled{color:var(--x-warning-400);cursor:not-allowed;background-image:none;background-color:var(--x-warning-900);border-color:var(--x-warning-800);box-shadow:none}.x-button-warning-plain.x-button-disabled:hover,.x-button-warning-plain.x-button-disabled:active,.x-button-warning-plain.x-button-disabled:focus{color:var(--x-warning-400);background-color:var(--x-warning-900);border-color:var(--x-warning-800)}.x-button-warning-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-warning.x-button-activated{z-index:2;color:var(--x-white);background-color:var(--x-warning);border-color:var(--x-warning)}.x-button-danger{color:var(--x-white);background-color:var(--x-danger);border-color:var(--x-danger)}.x-button-danger:hover{color:var(--x-white);background-color:var(--x-danger-100);border-color:var(--x-danger-100)}.x-button-danger:active{color:var(--x-white);background-color:var(--x-danger);border-color:var(--x-danger)}.x-button-danger:focus{color:var(--x-white);background-color:var(--x-danger);border-color:var(--x-danger);box-shadow:var(--x-box-shadow-focus)}.x-button-danger.x-button-disabled{color:var(--x-danger-800);cursor:not-allowed;background-image:none;background-color:var(--x-danger-500);border-color:var(--x-danger-500);box-shadow:none}.x-button-danger.x-button-disabled:hover,.x-button-danger.x-button-disabled:active,.x-button-danger.x-button-disabled:focus{color:var(--x-danger-800);background-color:var(--x-danger-500);border-color:var(--x-danger-500)}.x-button-danger.x-button-disabled:active .x-button-inner{transform:none}.x-button-danger-plain{color:var(--x-danger);background-color:var(--x-danger-900);border-color:var(--x-danger-600)}.x-button-danger-plain:hover{color:var(--x-background-900);background-color:var(--x-danger);border-color:var(--x-danger)}.x-button-danger-plain:active{color:var(--x-background-900);background-color:var(--x-danger-a100);border-color:var(--x-danger-a100)}.x-button-danger-plain:focus{color:var(--x-background-900);background-color:var(--x-danger-a100);border-color:var(--x-danger-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-danger-plain.x-button-disabled{color:var(--x-danger-400);cursor:not-allowed;background-image:none;background-color:var(--x-danger-900);border-color:var(--x-danger-800);box-shadow:none}.x-button-danger-plain.x-button-disabled:hover,.x-button-danger-plain.x-button-disabled:active,.x-button-danger-plain.x-button-disabled:focus{color:var(--x-danger-400);background-color:var(--x-danger-900);border-color:var(--x-danger-800)}.x-button-danger-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-danger.x-button-activated{z-index:2;color:var(--x-white);background-color:var(--x-danger);border-color:var(--x-danger)}.x-button-info{color:var(--x-white);background-color:var(--x-info);border-color:var(--x-info)}.x-button-info:hover{color:var(--x-white);background-color:var(--x-info-100);border-color:var(--x-info-100)}.x-button-info:active{color:var(--x-white);background-color:var(--x-info);border-color:var(--x-info)}.x-button-info:focus{color:var(--x-white);background-color:var(--x-info);border-color:var(--x-info);box-shadow:var(--x-box-shadow-focus)}.x-button-info.x-button-disabled{color:var(--x-info-800);cursor:not-allowed;background-image:none;background-color:var(--x-info-500);border-color:var(--x-info-500);box-shadow:none}.x-button-info.x-button-disabled:hover,.x-button-info.x-button-disabled:active,.x-button-info.x-button-disabled:focus{color:var(--x-info-800);background-color:var(--x-info-500);border-color:var(--x-info-500)}.x-button-info.x-button-disabled:active .x-button-inner{transform:none}.x-button-info-plain{color:var(--x-info);background-color:var(--x-info-900);border-color:var(--x-info-600)}.x-button-info-plain:hover{color:var(--x-background-900);background-color:var(--x-info);border-color:var(--x-info)}.x-button-info-plain:active{color:var(--x-background-900);background-color:var(--x-info-a100);border-color:var(--x-info-a100)}.x-button-info-plain:focus{color:var(--x-background-900);background-color:var(--x-info-a100);border-color:var(--x-info-a100);box-shadow:var(--x-box-shadow-focus)}.x-button-info-plain.x-button-disabled{color:var(--x-info-400);cursor:not-allowed;background-image:none;background-color:var(--x-info-900);border-color:var(--x-info-800);box-shadow:none}.x-button-info-plain.x-button-disabled:hover,.x-button-info-plain.x-button-disabled:active,.x-button-info-plain.x-button-disabled:focus{color:var(--x-info-400);background-color:var(--x-info-900);border-color:var(--x-info-800)}.x-button-info-plain.x-button-disabled:active .x-button-inner{transform:none}.x-button-info.x-button-activated{z-index:2;color:var(--x-white);background-color:var(--x-info);border-color:var(--x-info)}\n"] }]
|
|
225
234
|
}], ctorParameters: function () { return [{ type: XButtonsComponent, decorators: [{
|
|
226
235
|
type: Optional
|
|
227
236
|
}, {
|