@acorex/components 7.0.8 → 7.0.10
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/action-sheet/public-api.d.ts +1 -1
- package/action-sheet/src/action-sheet.component.d.ts +19 -13
- package/action-sheet/src/action-sheet.interface.d.ts +20 -0
- package/action-sheet/src/action-sheet.module.d.ts +8 -4
- package/action-sheet/src/action-sheet.service.d.ts +13 -0
- package/alert/src/alert.component.d.ts +2 -2
- package/badge/src/badge.component.d.ts +2 -2
- package/breadcrumbs/src/breadcrumbs-item.component.d.ts +6 -6
- package/button/src/button-group.component.d.ts +6 -6
- package/button/src/button-item.component.d.ts +6 -6
- package/color-picker/src/color-picker.component.d.ts +16 -16
- package/common/public-api.d.ts +12 -12
- package/common/src/{components.class.d.ts → classes/components.class.d.ts} +21 -1
- package/common/src/{drawing.class.d.ts → classes/drawing.class.d.ts} +0 -0
- package/common/src/{events.class.d.ts → classes/events.class.d.ts} +0 -0
- package/common/src/{styles.class.d.ts → classes/styles.class.d.ts} +0 -0
- package/common/src/common.module.d.ts +5 -5
- package/common/src/{auto-focus.directive.d.ts → directives/auto-focus.directive.d.ts} +1 -1
- package/common/src/{debounce-time.directive.d.ts → directives/debounce-time.directive.d.ts} +0 -0
- package/common/src/{hotkey.directive.d.ts → directives/hotkey.directive.d.ts} +2 -2
- package/common/src/{infinite-scroll.directive.d.ts → directives/infinite-scroll.directive.d.ts} +0 -0
- package/common/src/{responsive.directive.d.ts → directives/responsive.directive.d.ts} +0 -0
- package/common/src/{custom-cdk-overlay.service.d.ts → services/custom-cdk-overlay.service.d.ts} +0 -0
- package/common/src/{hotkey.service.d.ts → services/hotkey.service.d.ts} +0 -0
- package/common/src/{overlay.service.d.ts → services/overlay.service.d.ts} +4 -3
- package/context-menu/src/context-menu.component.d.ts +1 -1
- package/date-picker/src/datepicker.component.d.ts +14 -14
- package/dialog/src/dialog.class.d.ts +2 -1
- package/esm2020/action-sheet/public-api.mjs +2 -2
- package/esm2020/action-sheet/src/action-sheet.component.mjs +49 -74
- package/esm2020/action-sheet/src/action-sheet.interface.mjs +3 -0
- package/esm2020/action-sheet/src/action-sheet.module.mjs +12 -7
- package/esm2020/action-sheet/src/action-sheet.service.mjs +85 -0
- package/esm2020/button/src/button.component.mjs +2 -2
- package/esm2020/common/public-api.mjs +13 -13
- package/esm2020/common/src/classes/components.class.mjs +71 -0
- package/esm2020/common/src/classes/drawing.class.mjs +2 -0
- package/esm2020/common/src/classes/events.class.mjs +58 -0
- package/esm2020/common/src/classes/styles.class.mjs +22 -0
- package/esm2020/common/src/common.module.mjs +6 -6
- package/esm2020/common/src/directives/auto-focus.directive.mjs +55 -0
- package/esm2020/common/src/directives/debounce-time.directive.mjs +47 -0
- package/esm2020/common/src/directives/hotkey.directive.mjs +79 -0
- package/esm2020/common/src/directives/infinite-scroll.directive.mjs +63 -0
- package/esm2020/common/src/directives/responsive.directive.mjs +34 -0
- package/esm2020/common/src/services/custom-cdk-overlay.service.mjs +48 -0
- package/esm2020/common/src/services/hotkey.service.mjs +38 -0
- package/esm2020/common/src/services/overlay.service.mjs +96 -0
- package/esm2020/context-menu/src/context-menu.component.mjs +4 -4
- package/esm2020/decorators/src/close-button.component.mjs +4 -4
- package/esm2020/dialog/src/dialog.class.mjs +1 -1
- package/esm2020/dialog/src/dialog.component.mjs +3 -3
- package/esm2020/dialog/src/dialog.service.mjs +2 -1
- package/esm2020/menu/src/menu.component.mjs +16 -16
- package/esm2020/mixin/src/base-menu-mixin.class.mjs +3 -3
- package/esm2020/page/src/base-page.class.mjs +1 -27
- package/esm2020/popup/src/popup.component.mjs +4 -5
- package/esm2020/popup/src/popup.service.mjs +3 -3
- package/esm2020/range-slider/src/range-slider.component.mjs +2 -2
- package/esm2020/tabs/src/tab-content.directive.mjs +1 -1
- package/esm2020/tabs/src/tab-item.component.mjs +1 -1
- package/esm2020/tabs/src/tabs.component.mjs +1 -1
- package/esm2020/toast/src/toast.class.mjs +1 -1
- package/esm2020/toast/src/toast.component.mjs +29 -21
- package/esm2020/toast/src/toast.module.mjs +3 -6
- package/fesm2015/acorex-components-action-sheet.mjs +140 -124
- package/fesm2015/acorex-components-action-sheet.mjs.map +1 -1
- package/fesm2015/acorex-components-alert.mjs +0 -1
- package/fesm2015/acorex-components-avatar.mjs +0 -1
- package/fesm2015/acorex-components-badge.mjs +0 -1
- package/fesm2015/acorex-components-breadcrumbs.mjs +0 -1
- package/fesm2015/acorex-components-button.mjs +2 -3
- package/fesm2015/acorex-components-button.mjs.map +1 -1
- package/fesm2015/acorex-components-calendar.mjs +0 -1
- package/fesm2015/acorex-components-checkbox.mjs +0 -1
- package/fesm2015/acorex-components-chips.mjs +0 -1
- package/fesm2015/acorex-components-collapse.mjs +0 -1
- package/fesm2015/acorex-components-color-palette.mjs +0 -1
- package/fesm2015/acorex-components-color-picker.mjs +0 -1
- package/fesm2015/acorex-components-common.mjs +149 -120
- package/fesm2015/acorex-components-common.mjs.map +1 -1
- package/fesm2015/acorex-components-context-menu.mjs +3 -4
- package/fesm2015/acorex-components-context-menu.mjs.map +1 -1
- package/fesm2015/acorex-components-data-pager.mjs +0 -1
- package/fesm2015/acorex-components-data-table.mjs +0 -1
- package/fesm2015/acorex-components-date-picker.mjs +0 -1
- package/fesm2015/acorex-components-decorators.mjs +3 -4
- package/fesm2015/acorex-components-decorators.mjs.map +1 -1
- package/fesm2015/acorex-components-dialog.mjs +3 -3
- package/fesm2015/acorex-components-dialog.mjs.map +1 -1
- package/fesm2015/acorex-components-drawer.mjs +0 -1
- package/fesm2015/acorex-components-dropdown.mjs +0 -1
- package/fesm2015/acorex-components-form.mjs +0 -1
- package/fesm2015/acorex-components-image.mjs +0 -1
- package/fesm2015/acorex-components-label.mjs +0 -1
- package/fesm2015/acorex-components-loading.mjs +0 -1
- package/fesm2015/acorex-components-menu.mjs +15 -16
- package/fesm2015/acorex-components-menu.mjs.map +1 -1
- package/fesm2015/acorex-components-mixin.mjs +2 -3
- package/fesm2015/acorex-components-mixin.mjs.map +1 -1
- package/fesm2015/acorex-components-number-box.mjs +0 -1
- package/fesm2015/acorex-components-page.mjs +1 -28
- package/fesm2015/acorex-components-page.mjs.map +1 -1
- package/fesm2015/acorex-components-password-box.mjs +0 -1
- package/fesm2015/acorex-components-popover.mjs +0 -1
- package/fesm2015/acorex-components-popup.mjs +4 -6
- package/fesm2015/acorex-components-popup.mjs.map +1 -1
- package/fesm2015/acorex-components-progress-bar.mjs +0 -1
- package/fesm2015/acorex-components-radio.mjs +0 -1
- package/fesm2015/acorex-components-range-slider.mjs +2 -3
- package/fesm2015/acorex-components-range-slider.mjs.map +1 -1
- package/fesm2015/acorex-components-rating.mjs +0 -1
- package/fesm2015/acorex-components-result.mjs +0 -1
- package/fesm2015/acorex-components-search-box.mjs +0 -1
- package/fesm2015/acorex-components-select-box.mjs +0 -1
- package/fesm2015/acorex-components-selection-list.mjs +0 -1
- package/fesm2015/acorex-components-switch.mjs +0 -1
- package/fesm2015/acorex-components-tabs.mjs.map +1 -1
- package/fesm2015/acorex-components-tag.mjs +0 -1
- package/fesm2015/acorex-components-textarea.mjs +0 -1
- package/fesm2015/acorex-components-textbox.mjs +0 -1
- package/fesm2015/acorex-components-time-box.mjs +0 -1
- package/fesm2015/acorex-components-toast.mjs +30 -26
- package/fesm2015/acorex-components-toast.mjs.map +1 -1
- package/fesm2015/acorex-components-tooltip.mjs +0 -1
- package/fesm2015/acorex-components-tree-view.mjs +0 -1
- package/fesm2015/acorex-components-uploader.mjs +0 -1
- package/fesm2015/acorex-components.mjs +0 -1
- package/fesm2020/acorex-components-action-sheet.mjs +139 -124
- package/fesm2020/acorex-components-action-sheet.mjs.map +1 -1
- package/fesm2020/acorex-components-alert.mjs +0 -1
- package/fesm2020/acorex-components-avatar.mjs +0 -1
- package/fesm2020/acorex-components-badge.mjs +0 -1
- package/fesm2020/acorex-components-breadcrumbs.mjs +0 -1
- package/fesm2020/acorex-components-button.mjs +2 -3
- package/fesm2020/acorex-components-button.mjs.map +1 -1
- package/fesm2020/acorex-components-calendar.mjs +0 -1
- package/fesm2020/acorex-components-checkbox.mjs +0 -1
- package/fesm2020/acorex-components-chips.mjs +0 -1
- package/fesm2020/acorex-components-collapse.mjs +0 -1
- package/fesm2020/acorex-components-color-palette.mjs +0 -1
- package/fesm2020/acorex-components-color-picker.mjs +0 -1
- package/fesm2020/acorex-components-common.mjs +149 -120
- package/fesm2020/acorex-components-common.mjs.map +1 -1
- package/fesm2020/acorex-components-context-menu.mjs +3 -4
- package/fesm2020/acorex-components-context-menu.mjs.map +1 -1
- package/fesm2020/acorex-components-data-pager.mjs +0 -1
- package/fesm2020/acorex-components-data-table.mjs +0 -1
- package/fesm2020/acorex-components-date-picker.mjs +0 -1
- package/fesm2020/acorex-components-decorators.mjs +3 -4
- package/fesm2020/acorex-components-decorators.mjs.map +1 -1
- package/fesm2020/acorex-components-dialog.mjs +3 -3
- package/fesm2020/acorex-components-dialog.mjs.map +1 -1
- package/fesm2020/acorex-components-drawer.mjs +0 -1
- package/fesm2020/acorex-components-dropdown.mjs +0 -1
- package/fesm2020/acorex-components-form.mjs +0 -1
- package/fesm2020/acorex-components-image.mjs +0 -1
- package/fesm2020/acorex-components-label.mjs +0 -1
- package/fesm2020/acorex-components-loading.mjs +0 -1
- package/fesm2020/acorex-components-menu.mjs +15 -16
- package/fesm2020/acorex-components-menu.mjs.map +1 -1
- package/fesm2020/acorex-components-mixin.mjs +2 -3
- package/fesm2020/acorex-components-mixin.mjs.map +1 -1
- package/fesm2020/acorex-components-number-box.mjs +0 -1
- package/fesm2020/acorex-components-page.mjs +1 -28
- package/fesm2020/acorex-components-page.mjs.map +1 -1
- package/fesm2020/acorex-components-password-box.mjs +0 -1
- package/fesm2020/acorex-components-popover.mjs +0 -1
- package/fesm2020/acorex-components-popup.mjs +4 -6
- package/fesm2020/acorex-components-popup.mjs.map +1 -1
- package/fesm2020/acorex-components-progress-bar.mjs +0 -1
- package/fesm2020/acorex-components-radio.mjs +0 -1
- package/fesm2020/acorex-components-range-slider.mjs +2 -3
- package/fesm2020/acorex-components-range-slider.mjs.map +1 -1
- package/fesm2020/acorex-components-rating.mjs +0 -1
- package/fesm2020/acorex-components-result.mjs +0 -1
- package/fesm2020/acorex-components-search-box.mjs +0 -1
- package/fesm2020/acorex-components-select-box.mjs +0 -1
- package/fesm2020/acorex-components-selection-list.mjs +0 -1
- package/fesm2020/acorex-components-switch.mjs +0 -1
- package/fesm2020/acorex-components-tabs.mjs.map +1 -1
- package/fesm2020/acorex-components-tag.mjs +0 -1
- package/fesm2020/acorex-components-textarea.mjs +0 -1
- package/fesm2020/acorex-components-textbox.mjs +0 -1
- package/fesm2020/acorex-components-time-box.mjs +0 -1
- package/fesm2020/acorex-components-toast.mjs +30 -26
- package/fesm2020/acorex-components-toast.mjs.map +1 -1
- package/fesm2020/acorex-components-tooltip.mjs +0 -1
- package/fesm2020/acorex-components-tree-view.mjs +0 -1
- package/fesm2020/acorex-components-uploader.mjs +0 -1
- package/fesm2020/acorex-components.mjs +0 -1
- package/menu/src/menu.component.d.ts +1 -1
- package/mixin/src/base-components.class.d.ts +2 -2
- package/mixin/src/base-menu-mixin.class.d.ts +6 -6
- package/mixin/src/button-mixin.class.d.ts +2 -2
- package/mixin/src/clickable-mixin.class.d.ts +2 -2
- package/mixin/src/color-look-mixing.class.d.ts +2 -2
- package/mixin/src/datalist-component.class.d.ts +10 -10
- package/mixin/src/dropdown-mixin.class.d.ts +2 -2
- package/mixin/src/interactive-mixin.class.d.ts +4 -4
- package/mixin/src/loading-mixin.class.d.ts +2 -2
- package/mixin/src/mixin.class.d.ts +62 -62
- package/mixin/src/page-component.class.d.ts +2 -2
- package/mixin/src/selection-component.class.d.ts +2 -2
- package/mixin/src/sizable-mixin.class.d.ts +2 -2
- package/mixin/src/textbox-mixin.class.d.ts +2 -2
- package/mixin/src/value-mixin.class.d.ts +8 -8
- package/package.json +1 -1
- package/page/src/base-page.class.d.ts +3 -23
- package/popup/src/popup.component.d.ts +2 -2
- package/popup/src/popup.service.d.ts +3 -4
- package/tabs/src/tab-content.directive.d.ts +2 -2
- package/tabs/src/tab-item.component.d.ts +4 -4
- package/toast/src/toast.class.d.ts +1 -0
- package/toast/src/toast.component.d.ts +1 -0
- package/toast/src/toast.module.d.ts +1 -4
- package/action-sheet/src/action-sheet-item.component.d.ts +0 -16
- package/esm2020/action-sheet/src/action-sheet-item.component.mjs +0 -47
- package/esm2020/common/src/auto-focus.directive.mjs +0 -55
- package/esm2020/common/src/components.class.mjs +0 -45
- package/esm2020/common/src/custom-cdk-overlay.service.mjs +0 -48
- package/esm2020/common/src/debounce-time.directive.mjs +0 -47
- package/esm2020/common/src/drawing.class.mjs +0 -2
- package/esm2020/common/src/events.class.mjs +0 -58
- package/esm2020/common/src/hotkey.directive.mjs +0 -79
- package/esm2020/common/src/hotkey.service.mjs +0 -38
- package/esm2020/common/src/infinite-scroll.directive.mjs +0 -63
- package/esm2020/common/src/overlay.service.mjs +0 -91
- package/esm2020/common/src/responsive.directive.mjs +0 -34
- package/esm2020/common/src/styles.class.mjs +0 -22
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"acorex-components-toast.mjs","sources":["../../../../projects/acorex/components/toast/src/toast.component.ts","../../../../projects/acorex/components/toast/src/toast.component.html","../../../../projects/acorex/components/toast/src/toast.module.ts","../../../../projects/acorex/components/toast/src/toast.service.ts","../../../../projects/acorex/components/toast/acorex-components-toast.ts"],"sourcesContent":["import { AXClosbaleComponent } from '@acorex/components/common';\r\nimport { AXButtonItem } from '@acorex/components/button';\r\nimport {\r\n Component,\r\n ViewEncapsulation,\r\n ChangeDetectionStrategy,\r\n ElementRef,\r\n ChangeDetectorRef,\r\n} from '@angular/core';\r\nimport { AXToastOptions } from './toast.class';\r\nimport { AXBaseComponentMixin } from '@acorex/components/mixin';\r\n\r\n/**\r\n * The Button is a component which detects user interaction and triggers a corresponding event\r\n *\r\n * @category Components\r\n */\r\n@Component({\r\n selector: 'ax-toast',\r\n templateUrl: './toast.component.html',\r\n styleUrls: ['./toast.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n encapsulation: ViewEncapsulation.None,\r\n providers: [{ provide: AXClosbaleComponent, useExisting: AXToastComponent }],\r\n})\r\nexport class AXToastComponent extends AXBaseComponentMixin {\r\n\r\n options: AXToastOptions;\r\n\r\n _toastWidth: number = 100;\r\n\r\n _icon: string;\r\n \r\n close: () => void;\r\n /**\r\n * @ignore\r\n */\r\n constructor(elementRef: ElementRef, cdr: ChangeDetectorRef) {\r\n super(elementRef, cdr);\r\n }\r\n\r\n onInit() {\r\n if (this.options.timeOut) {\r\n setTimeout(() => {\r\n this.close();\r\n }, this.options.timeOut);\r\n }\r\n switch (this.options.color) {\r\n case 'success':\r\n this._icon = 'ax-icon ax-icon-check-filled';\r\n break;\r\n case 'warning':\r\n this._icon = 'ax-icon ax-icon-warning-filled';\r\n break;\r\n case 'danger':\r\n this._icon = 'ax-icon ax-icon-error-filled';\r\n break;\r\n default:\r\n this._icon = '';\r\n break;\r\n }\r\n }\r\n\r\n _handleButtonClick(button: AXButtonItem) {\r\n if (button.onClick) {\r\n button.onClick(this);\r\n }\r\n }\r\n}\r\n","<ax-alert [color]=\"options.color\" [timeOut]=\"options.timeOut\">\r\n <ax-icon *ngIf=\"_icon\" [icon]=\"_icon\"></ax-icon>\r\n <ax-title [text]=\"options.title\"></ax-title>\r\n <ax-close-button *ngIf=\"options.closeable\"></ax-close-button>\r\n <ax-content *ngIf=\"options.content\">\r\n <div [innerHTML]=\"options.content\"></div>\r\n </ax-content>\r\n <ax-footer *ngIf=\"options?.buttons?.length\">\r\n <ax-button *ngFor=\"let button of options.buttons\" [text]=\"button.text\" class=\"ax-sm\"\r\n (onClick)=\"_handleButtonClick(button)\" [color]=\"options.color\" [look]=\"'default'\"></ax-button>\r\n </ax-footer>\r\n</ax-alert>","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { AXToastComponent } from './toast.component';\r\nimport { AXAlertModule } from '@acorex/components/alert';\r\nimport { AXButtonModule } from '@acorex/components/button';\r\nimport { AXDecoratorModule } from '@acorex/components/decorators';\r\n\r\nconst COMPONENT = [AXToastComponent];\r\nconst MODULES = [CommonModule, AXButtonModule, AXDecoratorModule, AXAlertModule];\r\n\r\n@NgModule({\r\n declarations: [...COMPONENT],\r\n imports: [...MODULES],\r\n exports: [...COMPONENT],\r\n providers: [],\r\n})\r\nexport class AXToastModule {\r\n \r\n}\r\n","import { AXConfig } from '@acorex/core/config';\r\nimport { Overlay } from '@angular/cdk/overlay';\r\nimport { ComponentPortal } from '@angular/cdk/portal';\r\nimport { Injectable, Injector } from '@angular/core';\r\nimport { AXToastOptions, AXToastRef } from './toast.class';\r\nimport { AXToastComponent } from './toast.component';\r\n\r\n\r\n\r\n@Injectable({ providedIn: 'root' })\r\nexport class AXToastService {\r\n\r\n\r\n private readonly _defaults = {\r\n gap: 5,\r\n timeOut: 2500,\r\n location: 'bottom-center',\r\n }\r\n\r\n constructor(private overlayService: Overlay, private parentInjector: Injector) {\r\n\r\n }\r\n\r\n private _activeList: AXToastComponent[] = [];\r\n\r\n primary(content: string) {\r\n this.show({\r\n timeOut: AXConfig.get('toast.timeOut') || this._defaults.timeOut,\r\n color: 'primary',\r\n content: content\r\n });\r\n }\r\n secondary(content: string) {\r\n this.show({\r\n timeOut: AXConfig.get('toast.timeOut') || this._defaults.timeOut,\r\n color: 'secondary',\r\n content: content\r\n });\r\n }\r\n success(content: string) {\r\n this.show({\r\n timeOut: AXConfig.get('toast.timeOut') || this._defaults.timeOut,\r\n color: 'success',\r\n content: content\r\n });\r\n }\r\n\r\n warning(content: string) {\r\n this.show({\r\n timeOut: AXConfig.get('toast.timeOut') || this._defaults.timeOut,\r\n color: 'warning',\r\n content: content\r\n });\r\n }\r\n danger(content: string) {\r\n this.show({\r\n timeOut: AXConfig.get('toast.timeOut') || this._defaults.timeOut,\r\n color: 'danger',\r\n content: content\r\n });\r\n }\r\n show(options: AXToastOptions): AXToastRef {\r\n const opt = Object.assign(\r\n {\r\n closeable: true,\r\n location: AXConfig.get('toast.location') || this._defaults.location\r\n },\r\n options\r\n );\r\n const gap = AXConfig.get('toast.gap') || this._defaults.gap;\r\n\r\n let positionStrategy = this.overlayService.position().global();\r\n const pos = this.getPosition(opt.location) + gap + 'px';\r\n switch (opt.location) {\r\n case 'bottom-center':\r\n positionStrategy = positionStrategy.bottom(pos).centerHorizontally()\r\n break;\r\n case 'bottom-end':\r\n positionStrategy = positionStrategy.bottom(pos).right(gap + 'px');\r\n break;\r\n case 'bottom-start':\r\n positionStrategy = positionStrategy.bottom(pos).left(gap + 'px');\r\n break;\r\n case 'top-center':\r\n positionStrategy = positionStrategy.top(pos).centerHorizontally()\r\n break;\r\n case 'top-end':\r\n positionStrategy = positionStrategy.top(pos).right(gap + 'px');\r\n break;\r\n case 'top-start':\r\n positionStrategy = positionStrategy.top(pos).left(gap + 'px');\r\n break;\r\n case 'center-start':\r\n positionStrategy = positionStrategy.centerVertically().left(gap + 'px');\r\n break;\r\n case 'center-end':\r\n positionStrategy = positionStrategy.centerVertically().right(gap + 'px');\r\n break;\r\n default:\r\n break;\r\n }\r\n const overlayRef = this.overlayService.create(\r\n {\r\n positionStrategy,\r\n panelClass: ['ax-animate-animated', 'ax-animate-fadeIn', 'ax-animate-faster'],\r\n });\r\n const toastPortal = new ComponentPortal(AXToastComponent, null, this.parentInjector);\r\n\r\n const host = overlayRef.attach(toastPortal);\r\n (host.instance as any).visibleIndex = this._activeList.length;\r\n this._activeList.push(host.instance);\r\n if (host.instance) {\r\n Object.assign(host.instance, {\r\n options: opt,\r\n close: () => {\r\n this._activeList = this._activeList.filter(c => c != host.instance);\r\n overlayRef.dispose()\r\n }\r\n });\r\n setTimeout(() => {\r\n host.changeDetectorRef.detectChanges();\r\n }, 0);\r\n }\r\n\r\n return {\r\n close: () => {\r\n host.instance.close();\r\n }\r\n }\r\n }\r\n\r\n\r\n\r\n public hideAll() {\r\n this._activeList.forEach(c => c.close());\r\n }\r\n\r\n private getPosition(location: string) {\r\n const list = this._activeList.filter(c => c.options.location == location);\r\n if (list.length == 0) return 0;\r\n if (location.split('-')[0] == 'bottom') {\r\n return window.innerHeight - list[list.length - 1]._getHostElement().offsetTop;\r\n }\r\n else {\r\n return list[list.length - 1]._getHostElement().offsetTop + list[list.length - 1]._getHostElement().offsetHeight;\r\n }\r\n }\r\n}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["i1"],"mappings":";;;;;;;;;;;;;;;;AAYA;;;;AAIG;AASG,MAAO,gBAAiB,SAAQ,oBAAoB,CAAA;AASxD;;AAEG;IACH,WAAY,CAAA,UAAsB,EAAE,GAAsB,EAAA;AACxD,QAAA,KAAK,CAAC,UAAU,EAAE,GAAG,CAAC,CAAC;QATzB,IAAW,CAAA,WAAA,GAAW,GAAG,CAAC;KAUzB;IAED,MAAM,GAAA;AACJ,QAAA,IAAI,IAAI,CAAC,OAAO,CAAC,OAAO,EAAE;YACxB,UAAU,CAAC,MAAK;gBACd,IAAI,CAAC,KAAK,EAAE,CAAC;AACf,aAAC,EAAE,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC;AAC1B,SAAA;AACD,QAAA,QAAQ,IAAI,CAAC,OAAO,CAAC,KAAK;AACxB,YAAA,KAAK,SAAS;AACZ,gBAAA,IAAI,CAAC,KAAK,GAAG,8BAA8B,CAAC;gBAC5C,MAAM;AACR,YAAA,KAAK,SAAS;AACZ,gBAAA,IAAI,CAAC,KAAK,GAAG,gCAAgC,CAAC;gBAC9C,MAAM;AACR,YAAA,KAAK,QAAQ;AACX,gBAAA,IAAI,CAAC,KAAK,GAAG,8BAA8B,CAAC;gBAC5C,MAAM;AACR,YAAA;AACE,gBAAA,IAAI,CAAC,KAAK,GAAG,EAAE,CAAC;gBAChB,MAAM;AACT,SAAA;KACF;AAED,IAAA,kBAAkB,CAAC,MAAoB,EAAA;QACrC,IAAI,MAAM,CAAC,OAAO,EAAE;AAClB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AACnH,SAAA;KACJ;;2GAxIQ,cAAc,EAAA,IAAA,EAAA,CAAA,EAAA,KAAA,EAAAA,IAAA,CAAA,OAAA,EAAA,EAAA,EAAA,KAAA,EAAA,EAAA,CAAA,QAAA,EAAA,CAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;AAAd,cAAA,CAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,cAAc,cADD,MAAM,EAAA,CAAA,CAAA;2FACnB,cAAc,EAAA,UAAA,EAAA,CAAA;kBAD1B,UAAU;mBAAC,EAAE,UAAU,EAAE,MAAM,EAAE,CAAA;;;ACTlC;;AAEG;;;;"}
|
1
|
+
{"version":3,"file":"acorex-components-toast.mjs","sources":["../../../../projects/acorex/components/toast/src/toast.component.ts","../../../../projects/acorex/components/toast/src/toast.component.html","../../../../projects/acorex/components/toast/src/toast.module.ts","../../../../projects/acorex/components/toast/src/toast.service.ts","../../../../projects/acorex/components/toast/acorex-components-toast.ts"],"sourcesContent":["import { AXClosbaleComponent } from '@acorex/components/common';\r\nimport { AXButtonItem } from '@acorex/components/button';\r\nimport {\r\n Component,\r\n ViewEncapsulation,\r\n ChangeDetectionStrategy,\r\n ElementRef,\r\n ChangeDetectorRef,\r\n HostBinding,\r\n} from '@angular/core';\r\nimport { AXToastOptions } from './toast.class';\r\nimport { AXBaseComponentMixin } from '@acorex/components/mixin';\r\n\r\n/**\r\n * The Button is a component which detects user interaction and triggers a corresponding event\r\n *\r\n * @category Components\r\n */\r\n@Component({\r\n selector: 'ax-toast',\r\n templateUrl: './toast.component.html',\r\n styleUrls: ['./toast.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n encapsulation: ViewEncapsulation.None,\r\n providers: [{ provide: AXClosbaleComponent, useExisting: AXToastComponent }],\r\n})\r\nexport class AXToastComponent extends AXBaseComponentMixin {\r\n\r\n options: AXToastOptions;\r\n\r\n _toastWidth: number = 100;\r\n\r\n _icon: string;\r\n\r\n close: () => void;\r\n /**\r\n * @ignore\r\n */\r\n constructor(elementRef: ElementRef, cdr: ChangeDetectorRef) {\r\n super(elementRef, cdr);\r\n }\r\n\r\n onInit() {\r\n if (this.options.timeOut) {\r\n setTimeout(() => {\r\n this.close();\r\n }, this.options.timeOut);\r\n }\r\n if (!this.options.icon) {\r\n switch (this.options.color) {\r\n case 'success':\r\n this._icon = 'ax-icon ax-icon-check-circle-fill';\r\n break;\r\n case 'warning':\r\n this._icon = 'ax-icon ax-icon-warning-fill';\r\n break;\r\n case 'danger':\r\n this._icon = 'ax-icon ax-icon-error-fill';\r\n break;\r\n default:\r\n this._icon = this.options.icon || 'ax-icon ax-icon-check-circle-fill';\r\n break;\r\n }\r\n } else {\r\n this._icon = this.options.icon;\r\n }\r\n }\r\n\r\n _handleButtonClick(button: AXButtonItem) {\r\n if (button.onClick) {\r\n button.onClick(this);\r\n }\r\n }\r\n\r\n @HostBinding('class')\r\n private get __hostClass(): string {\r\n return `ax-${this.options.color}`\r\n }\r\n\r\n\r\n}\r\n","<!-- <ax-alert [color]=\"options.color\" [timeOut]=\"options.timeOut\">\r\n <ax-icon *ngIf=\"_icon\" [icon]=\"_icon\"></ax-icon>\r\n <ax-title [text]=\"options.title\"></ax-title>\r\n <ax-close-button *ngIf=\"options.closeable\"></ax-close-button>\r\n <ax-content *ngIf=\"options.content\">\r\n <div [innerHTML]=\"options.content\"></div>\r\n </ax-content>\r\n <ax-footer *ngIf=\"options?.buttons?.length\">\r\n <ax-button *ngFor=\"let button of options.buttons\" [text]=\"button.text\" class=\"ax-sm\"\r\n (onClick)=\"_handleButtonClick(button)\" [color]=\"options.color\" [look]=\"'default'\"></ax-button>\r\n </ax-footer>\r\n</ax-alert> -->\r\n<span [class]=\"'ax-toast-icon '+ _icon \"></span>\r\n<div class=\"ax-toast-content\">\r\n <div class=\"ax-toast-title\">{{options.title}}</div>\r\n <div [innerHTML]=\"options.content\"></div>\r\n <div class=\"ax-toast-buttons\" *ngIf=\"options?.buttons?.length\">\r\n <button *ngFor=\"let button of options.buttons\" (click)=\"_handleButtonClick(button)\">\r\n {{button.text}}\r\n </button>\r\n </div>\r\n</div>\r\n<span class=\"ax-icon ax-icon-close\" (click)=\"close()\"></span>\r\n<div class=\"ax-toast-progress\" [style.animation-duration.ms]=\"options.timeOut\" *ngIf=\"options.timeOut\"></div>","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { AXToastComponent } from './toast.component';\r\n\r\nconst COMPONENT = [AXToastComponent];\r\nconst MODULES = [CommonModule];\r\n\r\n@NgModule({\r\n declarations: [...COMPONENT],\r\n imports: [...MODULES],\r\n exports: [...COMPONENT],\r\n providers: [],\r\n})\r\nexport class AXToastModule {\r\n \r\n}\r\n","import { AXConfig } from '@acorex/core/config';\r\nimport { Overlay } from '@angular/cdk/overlay';\r\nimport { ComponentPortal } from '@angular/cdk/portal';\r\nimport { Injectable, Injector } from '@angular/core';\r\nimport { AXToastOptions, AXToastRef } from './toast.class';\r\nimport { AXToastComponent } from './toast.component';\r\n\r\n\r\n\r\n@Injectable({ providedIn: 'root' })\r\nexport class AXToastService {\r\n\r\n\r\n private readonly _defaults = {\r\n gap: 5,\r\n timeOut: 2500,\r\n location: 'bottom-center',\r\n }\r\n\r\n constructor(private overlayService: Overlay, private parentInjector: Injector) {\r\n\r\n }\r\n\r\n private _activeList: AXToastComponent[] = [];\r\n\r\n primary(content: string) {\r\n this.show({\r\n timeOut: AXConfig.get('toast.timeOut') || this._defaults.timeOut,\r\n color: 'primary',\r\n content: content\r\n });\r\n }\r\n secondary(content: string) {\r\n this.show({\r\n timeOut: AXConfig.get('toast.timeOut') || this._defaults.timeOut,\r\n color: 'secondary',\r\n content: content\r\n });\r\n }\r\n success(content: string) {\r\n this.show({\r\n timeOut: AXConfig.get('toast.timeOut') || this._defaults.timeOut,\r\n color: 'success',\r\n content: content\r\n });\r\n }\r\n\r\n warning(content: string) {\r\n this.show({\r\n timeOut: AXConfig.get('toast.timeOut') || this._defaults.timeOut,\r\n color: 'warning',\r\n content: content\r\n });\r\n }\r\n danger(content: string) {\r\n this.show({\r\n timeOut: AXConfig.get('toast.timeOut') || this._defaults.timeOut,\r\n color: 'danger',\r\n content: content\r\n });\r\n }\r\n show(options: AXToastOptions): AXToastRef {\r\n const opt = Object.assign(\r\n {\r\n closeable: true,\r\n location: AXConfig.get('toast.location') || this._defaults.location\r\n },\r\n options\r\n );\r\n const gap = AXConfig.get('toast.gap') || this._defaults.gap;\r\n\r\n let positionStrategy = this.overlayService.position().global();\r\n const pos = this.getPosition(opt.location) + gap + 'px';\r\n switch (opt.location) {\r\n case 'bottom-center':\r\n positionStrategy = positionStrategy.bottom(pos).centerHorizontally()\r\n break;\r\n case 'bottom-end':\r\n positionStrategy = positionStrategy.bottom(pos).right(gap + 'px');\r\n break;\r\n case 'bottom-start':\r\n positionStrategy = positionStrategy.bottom(pos).left(gap + 'px');\r\n break;\r\n case 'top-center':\r\n positionStrategy = positionStrategy.top(pos).centerHorizontally()\r\n break;\r\n case 'top-end':\r\n positionStrategy = positionStrategy.top(pos).right(gap + 'px');\r\n break;\r\n case 'top-start':\r\n positionStrategy = positionStrategy.top(pos).left(gap + 'px');\r\n break;\r\n case 'center-start':\r\n positionStrategy = positionStrategy.centerVertically().left(gap + 'px');\r\n break;\r\n case 'center-end':\r\n positionStrategy = positionStrategy.centerVertically().right(gap + 'px');\r\n break;\r\n default:\r\n break;\r\n }\r\n const overlayRef = this.overlayService.create(\r\n {\r\n positionStrategy,\r\n panelClass: ['ax-animate-animated', 'ax-animate-fadeIn', 'ax-animate-faster'],\r\n });\r\n const toastPortal = new ComponentPortal(AXToastComponent, null, this.parentInjector);\r\n\r\n const host = overlayRef.attach(toastPortal);\r\n (host.instance as any).visibleIndex = this._activeList.length;\r\n this._activeList.push(host.instance);\r\n if (host.instance) {\r\n Object.assign(host.instance, {\r\n options: opt,\r\n close: () => {\r\n this._activeList = this._activeList.filter(c => c != host.instance);\r\n overlayRef.dispose()\r\n }\r\n });\r\n setTimeout(() => {\r\n host.changeDetectorRef.detectChanges();\r\n }, 0);\r\n }\r\n\r\n return {\r\n close: () => {\r\n host.instance.close();\r\n }\r\n }\r\n }\r\n\r\n\r\n\r\n public hideAll() {\r\n this._activeList.forEach(c => c.close());\r\n }\r\n\r\n private getPosition(location: string) {\r\n const list = this._activeList.filter(c => c.options.location == location);\r\n if (list.length == 0) return 0;\r\n if (location.split('-')[0] == 'bottom') {\r\n return window.innerHeight - list[list.length - 1]._getHostElement().offsetTop;\r\n }\r\n else {\r\n return list[list.length - 1]._getHostElement().offsetTop + list[list.length - 1]._getHostElement().offsetHeight;\r\n }\r\n }\r\n}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["i1"],"mappings":";;;;;;;;;;AAaA;;;;AAIG;AASG,MAAO,gBAAiB,SAAQ,oBAAoB,CAAA;AASxD;;AAEG;IACH,WAAY,CAAA,UAAsB,EAAE,GAAsB,EAAA;AACxD,QAAA,KAAK,CAAC,UAAU,EAAE,GAAG,CAAC,CAAC;QATzB,IAAW,CAAA,WAAA,GAAW,GAAG,CAAC;KAUzB;IAED,MAAM,GAAA;AACJ,QAAA,IAAI,IAAI,CAAC,OAAO,CAAC,OAAO,EAAE;YACxB,UAAU,CAAC,MAAK;gBACd,IAAI,CAAC,KAAK,EAAE,CAAC;AACf,aAAC,EAAE,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC;AAC1B,SAAA;AACD,QAAA,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,IAAI,EAAE;AACtB,YAAA,QAAQ,IAAI,CAAC,OAAO,CAAC,KAAK;AACxB,gBAAA,KAAK,SAAS;AACZ,oBAAA,IAAI,CAAC,KAAK,GAAG,mCAAmC,CAAC;oBACjD,MAAM;AACR,gBAAA,KAAK,S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CAAA;2FACnB,cAAc,EAAA,UAAA,EAAA,CAAA;kBAD1B,UAAU;mBAAC,EAAE,UAAU,EAAE,MAAM,EAAE,CAAA;;;ACTlC;;AAEG;;;;"}
|
@@ -145,4 +145,3 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImpor
|
|
145
145
|
|
146
146
|
export { AXTooltipComponent, AXTooltipDirective, AXTooltipModule };
|
147
147
|
//# sourceMappingURL=acorex-components-tooltip.mjs.map
|
148
|
-
//# sourceMappingURL=acorex-components-tooltip.mjs.map
|
@@ -35,5 +35,5 @@ export declare class AXMenuComponent extends AXBaseMenuMixin implements OnInit {
|
|
35
35
|
private _close;
|
36
36
|
onDestroy(): void;
|
37
37
|
static ɵfac: i0.ɵɵFactoryDeclaration<AXMenuComponent, never>;
|
38
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<AXMenuComponent, "ax-menu", never, { "disabled": "disabled"; "tabIndex": "tabIndex"; "textField": "textField"; "valueField": "valueField"; "items": "items"; "parentId": "parentId"; "iconField": "iconField"; "tooltip": "tooltip"; "isOpen": "isOpen"; "isActive": "isActive"; "visibleField": "visibleField"; "disableField": "disableField"; "hasChildField": "hasChildField"; "dividerField": "dividerField"; "openMode": "openMode"; "
|
38
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<AXMenuComponent, "ax-menu", never, { "disabled": "disabled"; "tabIndex": "tabIndex"; "textField": "textField"; "valueField": "valueField"; "items": "items"; "parentId": "parentId"; "iconField": "iconField"; "tooltip": "tooltip"; "isOpen": "isOpen"; "isActive": "isActive"; "visibleField": "visibleField"; "disableField": "disableField"; "hasChildField": "hasChildField"; "dividerField": "dividerField"; "openMode": "openMode"; "displayMode": "displayMode"; "showModal": "showModal"; }, { "onBlur": "onBlur"; "onFocus": "onFocus"; "onMenuItemClick": "onMenuItemClick"; }, ["_contentEmptyTemplate", "_contentItemTemplate"], never, false, never>;
|
39
39
|
}
|
@@ -56,9 +56,9 @@ export declare function _BaseComponenetMixin<TBase extends Constructor<AXBaseCom
|
|
56
56
|
/**
|
57
57
|
* A token that specifies the layout direction of component.
|
58
58
|
*/
|
59
|
-
"__#
|
59
|
+
"__#34886@#rtl": boolean;
|
60
60
|
rtl: boolean;
|
61
|
-
"__#
|
61
|
+
"__#34886@#elementRef": ElementRef<any>;
|
62
62
|
_cdr: ChangeDetectorRef;
|
63
63
|
_isInited: boolean;
|
64
64
|
_isRendered: boolean;
|
@@ -6,17 +6,17 @@ export declare function _BaseMenuComponentMixin<TBase extends Constructor<AXBase
|
|
6
6
|
new (...args: any[]): {
|
7
7
|
textField: string;
|
8
8
|
valueField: string;
|
9
|
-
"__#
|
10
|
-
"__#
|
9
|
+
"__#34887@#isLoading": boolean;
|
10
|
+
"__#34887@#loadedItems": any;
|
11
11
|
visibleField: string;
|
12
12
|
disableField: string;
|
13
13
|
hasChildField: string;
|
14
14
|
iconField: string;
|
15
15
|
openMode: 'click' | 'hover';
|
16
|
-
|
16
|
+
displayMode: 'horizontal' | 'vertical' | 'sidemenu';
|
17
17
|
dividerField: string;
|
18
18
|
onMenuItemClick: EventEmitter<AXItemClickEvent<any>>;
|
19
|
-
"__#
|
19
|
+
"__#34887@#items": any;
|
20
20
|
items: any;
|
21
21
|
readonly displayItems: any;
|
22
22
|
readonly isLoading: boolean;
|
@@ -27,9 +27,9 @@ export declare function _BaseMenuComponentMixin<TBase extends Constructor<AXBase
|
|
27
27
|
_getItemDisplayTextTemplte(item: any): any;
|
28
28
|
refresh(): void;
|
29
29
|
id: string;
|
30
|
-
"__#
|
30
|
+
"__#34886@#rtl": boolean;
|
31
31
|
rtl: boolean;
|
32
|
-
"__#
|
32
|
+
"__#34886@#elementRef": import("@angular/core").ElementRef<any>;
|
33
33
|
_cdr: import("@angular/core").ChangeDetectorRef;
|
34
34
|
_isInited: boolean;
|
35
35
|
_isRendered: boolean;
|
@@ -26,9 +26,9 @@ export declare function _ButtonComponentMixin<TBase extends Constructor<AXBaseCo
|
|
26
26
|
'ax-state-selected': boolean;
|
27
27
|
};
|
28
28
|
id: string;
|
29
|
-
"__#
|
29
|
+
"__#34886@#rtl": boolean;
|
30
30
|
rtl: boolean;
|
31
|
-
"__#
|
31
|
+
"__#34886@#elementRef": import("@angular/core").ElementRef<any>;
|
32
32
|
_cdr: import("@angular/core").ChangeDetectorRef;
|
33
33
|
_isInited: boolean;
|
34
34
|
_isRendered: boolean;
|
@@ -13,9 +13,9 @@ export declare function _ClickableComponenetMixin<TBase extends Constructor<AXBa
|
|
13
13
|
id: string; /**
|
14
14
|
* @ignore
|
15
15
|
*/
|
16
|
-
"__#
|
16
|
+
"__#34886@#rtl": boolean;
|
17
17
|
rtl: boolean;
|
18
|
-
"__#
|
18
|
+
"__#34886@#elementRef": import("@angular/core").ElementRef<any>;
|
19
19
|
_cdr: import("@angular/core").ChangeDetectorRef;
|
20
20
|
_isInited: boolean;
|
21
21
|
_isRendered: boolean;
|
@@ -17,9 +17,9 @@ export declare function _ColorLookComponentMixin<TBase extends Constructor<AXBas
|
|
17
17
|
*/
|
18
18
|
look: AXStyleLookType;
|
19
19
|
id: string;
|
20
|
-
"__#
|
20
|
+
"__#34886@#rtl": boolean;
|
21
21
|
rtl: boolean;
|
22
|
-
"__#
|
22
|
+
"__#34886@#elementRef": import("@angular/core").ElementRef<any>;
|
23
23
|
_cdr: import("@angular/core").ChangeDetectorRef;
|
24
24
|
_isInited: boolean;
|
25
25
|
_isRendered: boolean;
|
@@ -7,16 +7,16 @@ export declare function _DatalistComponenetMixin<TBase extends Constructor<AXBas
|
|
7
7
|
textField: string;
|
8
8
|
childrenField: string;
|
9
9
|
pageSize: number;
|
10
|
-
"__#
|
11
|
-
"__#
|
12
|
-
"__#
|
13
|
-
"__#
|
14
|
-
"__#
|
15
|
-
"__#
|
10
|
+
"__#34888@#currentPage": number;
|
11
|
+
"__#34888@#isLoading": boolean;
|
12
|
+
"__#34888@#loadedItems": any[];
|
13
|
+
"__#34888@#flatItems": any[];
|
14
|
+
"__#34888@#totalItems": number;
|
15
|
+
"__#34888@#isLazy": boolean;
|
16
16
|
readonly totalCount: number;
|
17
17
|
readonly isLazy: boolean;
|
18
18
|
readonly loadedCount: number;
|
19
|
-
"__#
|
19
|
+
"__#34888@#items": AXDataListItems;
|
20
20
|
items: AXDataListItems;
|
21
21
|
readonly displayItems: any[];
|
22
22
|
readonly flatItems: any[];
|
@@ -26,15 +26,15 @@ export declare function _DatalistComponenetMixin<TBase extends Constructor<AXBas
|
|
26
26
|
searchQuery?: string;
|
27
27
|
}): void;
|
28
28
|
_onDataLoaded(): void;
|
29
|
-
"__#
|
29
|
+
"__#34888@#generateFlatItems"(): void;
|
30
30
|
_getItemDisplayTextTemplte(item: any): any;
|
31
31
|
_trackByFunction(item: any): any;
|
32
32
|
refresh(): void;
|
33
33
|
empty(): void;
|
34
34
|
id: string;
|
35
|
-
"__#
|
35
|
+
"__#34886@#rtl": boolean;
|
36
36
|
rtl: boolean;
|
37
|
-
"__#
|
37
|
+
"__#34886@#elementRef": import("@angular/core").ElementRef<any>;
|
38
38
|
_cdr: import("@angular/core").ChangeDetectorRef;
|
39
39
|
_isInited: boolean;
|
40
40
|
_isRendered: boolean;
|
@@ -23,9 +23,9 @@ export declare function _DropdownComponenetMixin<TBase extends Constructor<AXBas
|
|
23
23
|
open(): void;
|
24
24
|
readonly isOpen: boolean;
|
25
25
|
id: string;
|
26
|
-
"__#
|
26
|
+
"__#34886@#rtl": boolean;
|
27
27
|
rtl: boolean;
|
28
|
-
"__#
|
28
|
+
"__#34886@#elementRef": import("@angular/core").ElementRef<any>;
|
29
29
|
_cdr: import("@angular/core").ChangeDetectorRef;
|
30
30
|
_isInited: boolean;
|
31
31
|
_isRendered: boolean;
|
@@ -3,12 +3,12 @@ import { AXBaseComponent } from "./base-components.class";
|
|
3
3
|
import { Constructor } from "./constratctor";
|
4
4
|
import { AXFocusEvent } from "@acorex/components/common";
|
5
5
|
export declare function _InteractiveComponenetMixin<TBase extends Constructor<AXBaseComponent>>(Base: TBase): (abstract new (...args: any[]) => {
|
6
|
-
"__#
|
6
|
+
"__#34889@#disabled": boolean;
|
7
7
|
/**
|
8
8
|
* If set to true, it disables the component.
|
9
9
|
*/
|
10
10
|
disabled: boolean;
|
11
|
-
"__#
|
11
|
+
"__#34889@#tabIndex": number;
|
12
12
|
/**
|
13
13
|
* Specifies the tabindex of the component.
|
14
14
|
*/
|
@@ -34,9 +34,9 @@ export declare function _InteractiveComponenetMixin<TBase extends Constructor<AX
|
|
34
34
|
*/
|
35
35
|
hasFocus(): boolean;
|
36
36
|
id: string;
|
37
|
-
"__#
|
37
|
+
"__#34886@#rtl": boolean;
|
38
38
|
rtl: boolean;
|
39
|
-
"__#
|
39
|
+
"__#34886@#elementRef": import("@angular/core").ElementRef<any>;
|
40
40
|
_cdr: import("@angular/core").ChangeDetectorRef;
|
41
41
|
_isInited: boolean;
|
42
42
|
_isRendered: boolean;
|
@@ -16,9 +16,9 @@ export declare function _LoadingComponenetMixin<TBase extends Constructor<AXBase
|
|
16
16
|
loadingText: string;
|
17
17
|
_onInternalInit(): void;
|
18
18
|
id: string;
|
19
|
-
"__#
|
19
|
+
"__#34886@#rtl": boolean;
|
20
20
|
rtl: boolean;
|
21
|
-
"__#
|
21
|
+
"__#34886@#elementRef": import("@angular/core").ElementRef<any>;
|
22
22
|
_cdr: import("@angular/core").ChangeDetectorRef;
|
23
23
|
_isInited: boolean;
|
24
24
|
_isRendered: boolean;
|