@acorex/components 18.12.39 → 18.12.40
Sign up to get free protection for your applications and to get access to all the features.
- package/esm2022/form/lib/validation-rule.directive.mjs +1 -1
- package/esm2022/notification/lib/notification.component.mjs +4 -4
- package/esm2022/notification/lib/notification.service.mjs +53 -36
- package/esm2022/toast/lib/toast.component.mjs +2 -2
- package/esm2022/toast/lib/toast.config.mjs +2 -1
- package/esm2022/toast/lib/toast.service.mjs +130 -36
- package/fesm2022/acorex-components-form.mjs.map +1 -1
- package/fesm2022/acorex-components-notification.mjs +54 -37
- package/fesm2022/acorex-components-notification.mjs.map +1 -1
- package/fesm2022/acorex-components-toast.mjs +130 -35
- package/fesm2022/acorex-components-toast.mjs.map +1 -1
- package/form/lib/validation-rule.directive.d.ts +1 -1
- package/notification/lib/notification.component.d.ts +3 -3
- package/notification/lib/notification.service.d.ts +2 -0
- package/package.json +1 -1
- package/toast/lib/toast.component.d.ts +1 -1
- package/toast/lib/toast.config.d.ts +1 -0
- package/toast/lib/toast.service.d.ts +9 -1
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"acorex-components-toast.mjs","sources":["../../../../libs/components/toast/src/lib/toast.component.ts","../../../../libs/components/toast/src/lib/toast.component.html","../../../../libs/components/toast/src/lib/toast.config.ts","../../../../libs/components/toast/src/lib/toast.service.ts","../../../../libs/components/toast/src/lib/toast.module.ts","../../../../libs/components/toast/src/acorex-components-toast.ts"],"sourcesContent":["import { AXButtonItem } from '@acorex/components/button';\nimport { AXClosbaleComponent, AXComponentCloseEvent, MXBaseComponent } from '@acorex/components/common';\nimport { DIALOG_DATA, DialogRef } from '@angular/cdk/dialog';\nimport { ChangeDetectionStrategy, Component, HostBinding, Inject, OnInit, ViewEncapsulation } from '@angular/core';\nimport { AXToastData } from './toast.class';\n\n/**\n * The Button is a component which detects user interaction and triggers a corresponding event\n *\n * @category Components\n */\n@Component({\n selector: 'ax-toast',\n templateUrl: './toast.component.html',\n styleUrls: ['./toast.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n providers: [{ provide: AXClosbaleComponent, useExisting: AXToastComponent }],\n})\nexport class AXToastComponent extends MXBaseComponent implements OnInit {\n /** @ignore */\n protected _toastWidth = 100;\n\n /** @ignore */\n protected _icon: string;\n\n /**\n * @ignore\n */\n constructor(\n @Inject(DIALOG_DATA)\n public config: AXToastData,\n private dialogRef: DialogRef<AXComponentCloseEvent>,\n ) {\n super();\n }\n\n /** @ignore */\n override ngOnInit() {\n super.ngOnInit();\n if (this.config.timeOut) {\n setTimeout(() => {\n this.close();\n }, this.config.timeOut);\n }\n if (!this.config.icon) {\n switch (this.config.color) {\n case 'success':\n this._icon = 'ax-icon ax-icon-check-circle';\n break;\n case 'warning':\n this._icon = 'ax-icon ax-icon-warning';\n break;\n case 'danger':\n this._icon = 'ax-icon ax-icon-error';\n break;\n case 'info':\n this._icon = 'ax-icon ax-icon-info';\n break;\n default:\n this._icon = this.config.icon || 'ax-icon ax-icon-check-circle';\n break;\n }\n } else {\n this._icon = this.config.icon;\n }\n }\n\n /** @ignore */\n _handleButtonClick(button: AXButtonItem) {\n if (button.onClick) {\n button.onClick({ source: button });\n }\n }\n\n /** @ignore */\n @HostBinding('class')\n private get __hostClass(): string {\n return `ax-${this.config.color}`;\n }\n\n /** @ignore */\n close() {\n this.dialogRef.close({\n component: this,\n htmlElement: this.getHostElement(),\n });\n }\n}\n","<span class=\"ax-toast-icon ax-icon-solid {{ _icon }}\"></span>\n<div class=\"ax-toast-content\">\n <div class=\"ax-toast-title\" [class.ax-mb-2]=\"config.title && config.content\">{{ config.title | translate | async }}\n </div>\n <div class=\"ax-toast-content\" [innerHTML]=\"config.content\"></div>\n</div>\n@if(config.closeButton){\n<ax-close-button></ax-close-button>\n}\n@if(config.timeOutProgress && config.timeOut){\n<div class=\"ax-toast-progress\" [style.animation-duration.ms]=\"config.timeOut\"></div>\n}","import { AXLocation } from '@acorex/components/common';\nimport { AX_GLOBAL_CONFIG } from '@acorex/core/config';\nimport { InjectionToken, inject } from '@angular/core';\nimport { set } from 'lodash-es';\n\nexport interface AXToastConfig {\n gap: number;\n timeOut: number;\n timeOutProgress: boolean;\n location: AXLocation;\n}\n\nexport const AX_TOAST_CONFIG = new InjectionToken<AXToastConfig>('AX_TOAST_CONFIG', {\n providedIn: 'root',\n factory: () => {\n const global = inject(AX_GLOBAL_CONFIG);\n set(global, 'layout.toast', AX_TOAST_CONFIG);\n return AXToastDefaultConfig;\n },\n});\n\nexport const AXToastDefaultConfig: AXToastConfig = {\n gap: 5,\n timeOut: 2500,\n timeOutProgress: true,\n location: 'bottom-center',\n};\n\nexport type PartialToastConfig = Partial<AXToastConfig>;\n\nexport function toastConfig(config: PartialToastConfig = {}): AXToastConfig {\n const result = {\n ...AXToastDefaultConfig,\n ...config,\n };\n return result;\n}\n","import { Dialog } from '@angular/cdk/dialog';\nimport { GlobalPositionStrategy, ScrollStrategy, ScrollStrategyOptions } from '@angular/cdk/overlay';\nimport { Injectable, inject } from '@angular/core';\nimport { AXToastDisplayConfig, AXToastRef } from './toast.class';\nimport { AXToastComponent } from './toast.component';\nimport { AXToastConfig, AX_TOAST_CONFIG } from './toast.config';\n\n@Injectable()\nexport class AXToastService {\n private dialog: Dialog = inject(Dialog);\n private defaultConfig: AXToastConfig = inject(AX_TOAST_CONFIG);\n\n scrollStrategy: ScrollStrategy;\n\n constructor(private readonly scrollStrategyOptions: ScrollStrategyOptions) {\n this.scrollStrategy = this.scrollStrategyOptions.noop();\n }\n primary(content: string) {\n this.show({\n timeOut: this.defaultConfig.timeOut,\n color: 'primary',\n content: content,\n });\n }\n secondary(content: string) {\n this.show({\n timeOut: this.defaultConfig.timeOut,\n color: 'secondary',\n content: content,\n });\n }\n success(content: string) {\n this.show({\n timeOut: this.defaultConfig.timeOut,\n color: 'success',\n content: content,\n });\n }\n\n warning(content: string) {\n this.show({\n timeOut: this.defaultConfig.timeOut,\n color: 'warning',\n content: content,\n });\n }\n danger(content: string) {\n this.show({\n timeOut: this.defaultConfig.timeOut,\n color: 'danger',\n content: content,\n });\n }\n show(config: AXToastDisplayConfig): AXToastRef {\n const opt = Object.assign(\n {\n closeButton: true,\n location: this.defaultConfig.location ?? 'bottom-center',\n },\n config,\n );\n const gap = this.defaultConfig.gap;\n\n let positionStrategy = new GlobalPositionStrategy();\n const pos = this.getPosition(opt.location) + gap + 'px';\n switch (opt.location) {\n case 'bottom-center':\n positionStrategy = positionStrategy.bottom(pos).centerHorizontally();\n break;\n case 'bottom-end':\n positionStrategy = positionStrategy.bottom(pos).right(gap + 'px');\n break;\n case 'bottom-start':\n positionStrategy = positionStrategy.bottom(pos).left(gap + 'px');\n break;\n case 'top-center':\n positionStrategy = positionStrategy.top(pos).centerHorizontally();\n break;\n case 'top-end':\n positionStrategy = positionStrategy.top(pos).right(gap + 'px');\n break;\n case 'top-start':\n positionStrategy = positionStrategy.top(pos).left(gap + 'px');\n break;\n case 'center-start':\n positionStrategy = positionStrategy.centerVertically().left(gap + 'px');\n break;\n case 'center-end':\n positionStrategy = positionStrategy.centerVertically().right(gap + 'px');\n break;\n }\n\n const dialogRef = this.dialog.open(AXToastComponent, {\n data: opt,\n autoFocus: '__no_element__',\n restoreFocus: true,\n role: 'dialog',\n ariaModal: true,\n closeOnNavigation: true,\n closeOnDestroy: true,\n hasBackdrop: false,\n panelClass: ['ax-animate-animated', 'ax-animate-fadeIn', 'ax-animate-faster'],\n positionStrategy: positionStrategy,\n scrollStrategy: this.scrollStrategy,\n });\n\n const toastRef = dialogRef.componentInstance as AXToastComponent;\n dialogRef.closed.subscribe(() => {\n this.reposition();\n });\n\n return {\n close: () => {\n toastRef.close();\n },\n };\n }\n\n public hideAll() {\n this.dialog.closeAll();\n }\n\n private reposition(): void {\n //TODO: reposition vertically afer close toast\n }\n\n private getPosition(location: string) {\n const list = this.dialog.openDialogs.map((c) => c.componentInstance as AXToastComponent).filter((c) => c.config?.location == location);\n if (list.length == 0) return 0;\n if (location.split('-')[0] == 'bottom') {\n return window.innerHeight - list[list.length - 1].getHostElement().offsetTop;\n } else {\n return list[list.length - 1].getHostElement().offsetTop + list[list.length - 1].getHostElement().offsetHeight;\n }\n }\n}\n","import { AXButtonModule } from '@acorex/components/button';\nimport { AXDecoratorModule } from '@acorex/components/decorators';\nimport { AXLoadingModule } from '@acorex/components/loading';\nimport { AXTranslationModule } from '@acorex/core/translation';\nimport { DialogModule } from '@angular/cdk/dialog';\nimport { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { AXToastComponent } from './toast.component';\nimport { AXToastService } from './toast.service';\n\nconst COMPONENT = [AXToastComponent];\nconst MODULES = [CommonModule, AXButtonModule, AXDecoratorModule, AXLoadingModule, DialogModule, AXTranslationModule];\n\n@NgModule({\n declarations: [...COMPONENT],\n imports: [...MODULES],\n exports: [...COMPONENT],\n providers: [AXToastService],\n})\nexport class AXToastModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1"],"mappings":";;;;;;;;;;;;;;;;;;AAMA;;;;AAIG;AASG,MAAO,gBAAiB,SAAQ,eAAe,CAAA;AAOnD;;AAEG;IACH,WAES,CAAA,MAAmB,EAClB,SAA2C,EAAA;AAEnD,QAAA,KAAK,EAAE;QAHA,IAAM,CAAA,MAAA,GAAN,MAAM;QACL,IAAS,CAAA,SAAA,GAAT,SAAS;;QAXT,IAAW,CAAA,WAAA,GAAG,GAAG;;;IAiBlB,QAAQ,GAAA;QACf,KAAK,CAAC,QAAQ,EAAE;AAChB,QAAA,IAAI,IAAI,CAAC,MAAM,CAAC,OAAO,EAAE;YACvB,UAAU,CAAC,MAAK;gBACd,IAAI,CAAC,KAAK,EAAE;AACd,aAAC,EAAE,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC;;AAEzB,QAAA,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,IAAI,EAAE;AACrB,YAAA,QAAQ,IAAI,CAAC,MAAM,CAAC,KAAK;AACvB,gBAAA,KAAK,SAAS;AACZ,oBAAA,IAAI,CAA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AC;oBACvB,SAAS,EAAE,CAAC,cAAc,CAAC;AAC5B,iBAAA;;;AClBD;;AAEG;;;;"}
|
1
|
+
{"version":3,"file":"acorex-components-toast.mjs","sources":["../../../../libs/components/toast/src/lib/toast.component.ts","../../../../libs/components/toast/src/lib/toast.component.html","../../../../libs/components/toast/src/lib/toast.config.ts","../../../../libs/components/toast/src/lib/toast.service.ts","../../../../libs/components/toast/src/lib/toast.module.ts","../../../../libs/components/toast/src/acorex-components-toast.ts"],"sourcesContent":["import { AXButtonItem } from '@acorex/components/button';\nimport { AXClosbaleComponent, AXComponentCloseEvent, MXBaseComponent } from '@acorex/components/common';\nimport { DIALOG_DATA, DialogRef } from '@angular/cdk/dialog';\nimport {\n ChangeDetectionStrategy,\n Component,\n HostBinding,\n Inject,\n OnInit,\n ViewEncapsulation,\n} from '@angular/core';\nimport { AXToastData } from './toast.class';\n\n/**\n * The Button is a component which detects user interaction and triggers a corresponding event\n *\n * @category Components\n */\n@Component({\n selector: 'ax-toast',\n templateUrl: './toast.component.html',\n styleUrls: ['./toast.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n providers: [{ provide: AXClosbaleComponent, useExisting: AXToastComponent }],\n})\nexport class AXToastComponent extends MXBaseComponent implements OnInit {\n /** @ignore */\n protected _toastWidth = 100;\n\n /** @ignore */\n protected _icon: string;\n\n /**\n * @ignore\n */\n constructor(\n @Inject(DIALOG_DATA)\n public config: AXToastData,\n public dialogRef: DialogRef<AXComponentCloseEvent>,\n ) {\n super();\n }\n\n /** @ignore */\n override ngOnInit() {\n super.ngOnInit();\n if (this.config.timeOut) {\n setTimeout(() => {\n this.close();\n }, this.config.timeOut);\n }\n if (!this.config.icon) {\n switch (this.config.color) {\n case 'success':\n this._icon = 'ax-icon ax-icon-check-circle';\n break;\n case 'warning':\n this._icon = 'ax-icon ax-icon-warning';\n break;\n case 'danger':\n this._icon = 'ax-icon ax-icon-error';\n break;\n case 'info':\n this._icon = 'ax-icon ax-icon-info';\n break;\n default:\n this._icon = this.config.icon || 'ax-icon ax-icon-check-circle';\n break;\n }\n } else {\n this._icon = this.config.icon;\n }\n }\n\n /** @ignore */\n _handleButtonClick(button: AXButtonItem) {\n if (button.onClick) {\n button.onClick({ source: button });\n }\n }\n\n /** @ignore */\n @HostBinding('class')\n private get __hostClass(): string {\n return `ax-${this.config.color}`;\n }\n\n /** @ignore */\n close() {\n this.dialogRef.close({\n component: this,\n htmlElement: this.getHostElement(),\n });\n }\n}\n","<span class=\"ax-toast-icon ax-icon-solid {{ _icon }}\"></span>\n<div class=\"ax-toast-content\">\n <div class=\"ax-toast-title\" [class.ax-mb-2]=\"config.title && config.content\">{{ config.title | translate | async }}\n </div>\n <div class=\"ax-toast-content\" [innerHTML]=\"config.content\"></div>\n</div>\n@if(config.closeButton){\n<ax-close-button></ax-close-button>\n}\n@if(config.timeOutProgress && config.timeOut){\n<div class=\"ax-toast-progress\" [style.animation-duration.ms]=\"config.timeOut\"></div>\n}","import { AXLocation } from '@acorex/components/common';\nimport { AX_GLOBAL_CONFIG } from '@acorex/core/config';\nimport { InjectionToken, inject } from '@angular/core';\nimport { set } from 'lodash-es';\n\nexport interface AXToastConfig {\n gap: number;\n timeOut: number;\n timeOutProgress: boolean;\n location: AXLocation;\n limit?: number;\n}\n\nexport const AX_TOAST_CONFIG = new InjectionToken<AXToastConfig>('AX_TOAST_CONFIG', {\n providedIn: 'root',\n factory: () => {\n const global = inject(AX_GLOBAL_CONFIG);\n set(global, 'layout.toast', AX_TOAST_CONFIG);\n return AXToastDefaultConfig;\n },\n});\n\nexport const AXToastDefaultConfig: AXToastConfig = {\n gap: 5,\n timeOut: 2500,\n timeOutProgress: true,\n location: 'bottom-center',\n limit: 3,\n};\n\nexport type PartialToastConfig = Partial<AXToastConfig>;\n\nexport function toastConfig(config: PartialToastConfig = {}): AXToastConfig {\n const result = {\n ...AXToastDefaultConfig,\n ...config,\n };\n return result;\n}\n","import { AXLocation, AXStyleColorType } from '@acorex/components/common';\nimport { Dialog } from '@angular/cdk/dialog';\nimport { GlobalPositionStrategy, ScrollStrategy, ScrollStrategyOptions } from '@angular/cdk/overlay';\nimport { Injectable, WritableSignal, effect, inject, signal } from '@angular/core';\nimport { AXToastData, AXToastDisplayConfig, AXToastRef } from './toast.class';\nimport { AXToastComponent } from './toast.component';\nimport { AXToastConfig, AX_TOAST_CONFIG } from './toast.config';\n\n@Injectable()\nexport class AXToastService {\n private dialog: Dialog = inject(Dialog);\n private defaultConfig: AXToastConfig = inject(AX_TOAST_CONFIG);\n private activeToasts: WritableSignal<string[]> = signal([]);\n private reservedToasts: WritableSignal<AXToastDisplayConfig[]> = signal([]);\n private toastCounterElement: WritableSignal<AXToastComponent | null> = signal(null);\n private reserveCounter = signal(0);\n private moreToastsColor: WritableSignal<AXStyleColorType> = signal('primary');\n\n scrollStrategy: ScrollStrategy;\n\n constructor(private readonly scrollStrategyOptions: ScrollStrategyOptions) {\n this.scrollStrategy = this.scrollStrategyOptions.noop();\n if (this.defaultConfig.limit) {\n effect(\n () => {\n if (this.activeToasts().length <= this.defaultConfig.limit - 1 && this.reservedToasts().length) {\n this.show(this.reservedToasts()[0]);\n this.reservedToasts.update((value) => {\n const arr = [...value];\n arr.shift();\n return arr;\n });\n }\n if (this.reservedToasts().length !== this.reserveCounter()) {\n this.reserveCounter.set(this.reservedToasts().length);\n if (this.toastCounterElement() !== null) {\n this.toastCounterElement().close();\n }\n this.createReservedCounterToast();\n }\n if (this.reserveCounter() === 0) {\n if (this.toastCounterElement() !== null) {\n this.toastCounterElement().close();\n }\n }\n },\n { allowSignalWrites: true },\n );\n }\n }\n\n primary(content: string) {\n this.show({\n timeOut: this.defaultConfig.timeOut,\n color: 'primary',\n content: content,\n });\n }\n secondary(content: string) {\n this.show({\n timeOut: this.defaultConfig.timeOut,\n color: 'secondary',\n content: content,\n });\n }\n success(content: string) {\n this.show({\n timeOut: this.defaultConfig.timeOut,\n color: 'success',\n content: content,\n });\n }\n warning(content: string) {\n this.show({\n timeOut: this.defaultConfig.timeOut,\n color: 'warning',\n content: content,\n });\n }\n danger(content: string) {\n this.show({\n timeOut: this.defaultConfig.timeOut,\n color: 'danger',\n content: content,\n });\n }\n\n show(config: AXToastDisplayConfig): AXToastRef | void {\n const opt = Object.assign(\n {\n closeButton: true,\n location: this.defaultConfig.location ?? 'bottom-center',\n },\n config,\n );\n this.moreToastsColor.set(opt.color);\n\n if (this.defaultConfig.limit) {\n if (this.activeToasts().length >= this.defaultConfig.limit) {\n this.reservedToasts.update((value) => {\n return [...value, opt];\n });\n return;\n }\n }\n\n const gap = this.defaultConfig.gap;\n const pos = this.getPosition(opt.location) + gap + 'px';\n const positionStrategy = this.getPositionStrategy(new GlobalPositionStrategy(), opt.location, pos, gap);\n const dialogRef = this.dialog.open(AXToastComponent, {\n data: opt,\n autoFocus: '__no_element__',\n restoreFocus: true,\n role: 'dialog',\n ariaModal: true,\n closeOnNavigation: true,\n closeOnDestroy: true,\n hasBackdrop: false,\n panelClass: ['ax-animate-animated', 'ax-animate-fadeIn', 'ax-animate-faster'],\n positionStrategy,\n scrollStrategy: this.scrollStrategy,\n });\n\n this.activeToasts.update((value) => {\n return [...value, dialogRef.id];\n });\n\n const toastRef = dialogRef.componentInstance as AXToastComponent;\n dialogRef.closed.subscribe(() => {\n this.activeToasts.update((value) => {\n return [...value].filter((dialogID) => dialogID !== dialogRef.id);\n });\n setTimeout(() => {\n this.reposition(opt.location, gap);\n }, 0);\n });\n\n return {\n close: () => {\n toastRef.close();\n },\n };\n }\n\n public hideAll() {\n this.dialog.closeAll();\n }\n\n private createReservedCounterToast() {\n const opt: AXToastData = {\n closeButton: false,\n color: this.moreToastsColor(),\n location: 'bottom-center',\n title: `And ${this.reserveCounter()} more...`,\n timeOutProgress: false,\n };\n const gap = this.defaultConfig.gap;\n const pos = this.getPosition(opt.location) + gap + 'px';\n const positionStrategy = this.getPositionStrategy(new GlobalPositionStrategy(), opt.location, pos, gap);\n const dialogRef = this.dialog.open(AXToastComponent, {\n data: opt,\n autoFocus: '__no_element__',\n restoreFocus: true,\n role: 'dialog',\n ariaModal: true,\n closeOnNavigation: true,\n closeOnDestroy: true,\n hasBackdrop: false,\n panelClass: ['ax-animate-animated', 'ax-animate-fadeIn', 'ax-animate-faster'],\n positionStrategy,\n scrollStrategy: this.scrollStrategy,\n });\n this.toastCounterElement.set(dialogRef.componentInstance as AXToastComponent);\n }\n\n private reposition(toastLocation: AXLocation, gap: number): void {\n const list = this.dialog.openDialogs\n .map((c) => c.componentInstance as AXToastComponent)\n .filter((c) => c.config?.location == toastLocation);\n\n list.forEach((element, index) => {\n const pos = this.getRepositionPosition(index, gap, list, toastLocation);\n console.log(index, element);\n\n this.getPositionStrategy(\n element.dialogRef.config.positionStrategy as GlobalPositionStrategy,\n toastLocation,\n pos,\n gap,\n ).apply();\n });\n }\n\n private getRepositionPosition(index: number, gap: number, list: AXToastComponent[], toastLocation: string) {\n if (index === 0) {\n return gap + 'px';\n }\n const previouseElement = list[index - 1];\n if (toastLocation.split('-')[0] == 'bottom') {\n return window.innerHeight - previouseElement.getHostElement().offsetTop + gap + 'px';\n }\n return (\n previouseElement.getHostElement().offsetTop +\n previouseElement.getHostElement().offsetHeight +\n gap +\n 'px'\n );\n }\n\n private getPosition(location: string) {\n const list = this.dialog.openDialogs\n .map((c) => c.componentInstance as AXToastComponent)\n .filter((c) => c.config?.location == location);\n if (list.length == 0) return 0;\n if (location.split('-')[0] == 'bottom') {\n return window.innerHeight - list[list.length - 1].getHostElement().offsetTop;\n }\n return (\n list[list.length - 1].getHostElement().offsetTop + list[list.length - 1].getHostElement().offsetHeight\n );\n }\n\n private getPositionStrategy(\n positionStrategy: GlobalPositionStrategy,\n location: AXLocation,\n pos: string,\n gap: number,\n ) {\n switch (location) {\n case 'bottom-center':\n return positionStrategy.bottom(pos).centerHorizontally();\n break;\n case 'bottom-end':\n return positionStrategy.bottom(pos).right(gap + 'px');\n break;\n case 'bottom-start':\n return positionStrategy.bottom(pos).left(gap + 'px');\n break;\n case 'top-center':\n return positionStrategy.top(pos).centerHorizontally();\n break;\n case 'top-end':\n return positionStrategy.top(pos).right(gap + 'px');\n break;\n case 'top-start':\n return positionStrategy.top(pos).left(gap + 'px');\n break;\n case 'center-start':\n return positionStrategy.centerVertically().left(gap + 'px');\n break;\n case 'center-end':\n return positionStrategy.centerVertically().right(gap + 'px');\n break;\n }\n }\n}\n","import { AXButtonModule } from '@acorex/components/button';\nimport { AXDecoratorModule } from '@acorex/components/decorators';\nimport { AXLoadingModule } from '@acorex/components/loading';\nimport { AXTranslationModule } from '@acorex/core/translation';\nimport { DialogModule } from '@angular/cdk/dialog';\nimport { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { AXToastComponent } from './toast.component';\nimport { AXToastService } from './toast.service';\n\nconst COMPONENT = [AXToastComponent];\nconst MODULES = [CommonModule, AXButtonModule, AXDecoratorModule, AXLoadingModule, DialogModule, AXTranslationModule];\n\n@NgModule({\n declarations: [...COMPONENT],\n imports: [...MODULES],\n exports: [...COMPONENT],\n providers: [AXToastService],\n})\nexport class AXToastModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1"],"mappings":";;;;;;;;;;;;;;;;;;AAaA;;;;AAIG;AASG,MAAO,gBAAiB,SAAQ,eAAe,CAAA;AAOnD;;AAEG;IACH,WAES,CAAA,MAAmB,EACnB,SAA2C,EAAA;AAElD,QAAA,KAAK,EAAE;QAHA,IAAM,CAAA,MAAA,GAAN,MAAM;QACN,IAAS,CAAA,SAAA,GAAT,SAAS;;QAXR,IAAW,CAAA,WAAA,GAAG,GAAG;;;IAiBlB,QAAQ,GAAA;QACf,KAAK,CAAC,QAAQ,EAAE;AAChB,QAAA,IAAI,IAAI,CAAC,MAAM,CAAC,OAAO,EAAE;YACvB,UAAU,CAAC,MAAK;gBACd,IAAI,CAAC,KAAK,EAAE;AACd,aAAC,EAAE,IAAI,CAAC,MAAM,CAAC,OAAO,CAA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,EAAE,iBAAiB,EAAE,eAAe,EAAE,YAAY,EAAE,mBAAmB,CAAC;MAQxG,aAAa,CAAA;8GAAb,aAAa,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;AAAb,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,aAAa,EATP,YAAA,EAAA,CAAA,gBAAgB,CAClB,EAAA,OAAA,EAAA,CAAA,YAAY,EAAE,cAAc,EAAE,iBAAiB,EAAE,eAAe,EAAE,YAAY,EAAE,mBAAmB,aADjG,gBAAgB,CAAA,EAAA,CAAA,CAAA;AAStB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,aAAa,EAFb,SAAA,EAAA,CAAC,cAAc,CAAC,YAFd,OAAO,CAAA,EAAA,CAAA,CAAA;;2FAIT,aAAa,EAAA,UAAA,EAAA,CAAA;kBANzB,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,YAAY,EAAE,CAAC,GAAG,SAAS,CAAC;AAC5B,oBAAA,OAAO,EAAE,CAAC,GAAG,OAAO,CAAC;AACrB,oBAAA,OAAO,EAAE,CAAC,GAAG,SAAS,CAAC;oBACvB,SAAS,EAAE,CAAC,cAAc,CAAC;AAC5B,iBAAA;;;AClBD;;AAEG;;;;"}
|
@@ -4,7 +4,7 @@ import { OnDestroy, OnInit } from '@angular/core';
|
|
4
4
|
import * as i0 from "@angular/core";
|
5
5
|
export declare class AXValidationRuleDirective implements OnInit, OnDestroy {
|
6
6
|
private host;
|
7
|
-
rule:
|
7
|
+
rule: string;
|
8
8
|
options: Omit<AXValidationRuleOptions, 'message'>;
|
9
9
|
message: string;
|
10
10
|
constructor(host: AXValuableComponent);
|
@@ -10,7 +10,7 @@ import * as i0 from "@angular/core";
|
|
10
10
|
*/
|
11
11
|
export declare class AXNotificationComponent extends MXBaseComponent {
|
12
12
|
config: AXNotificationData;
|
13
|
-
|
13
|
+
dialogRef: DialogRef<AXComponentCloseEvent>;
|
14
14
|
/** @ignore */
|
15
15
|
_selectedPortal: Portal<unknown>;
|
16
16
|
/** @ignore */
|
@@ -32,8 +32,8 @@ export declare class AXNotificationComponent extends MXBaseComponent {
|
|
32
32
|
/** @ignore */
|
33
33
|
private get __hostClass();
|
34
34
|
/**
|
35
|
-
|
36
|
-
|
35
|
+
* Closes the dialog and provides the component and HTML element for reference.
|
36
|
+
*/
|
37
37
|
close(): void;
|
38
38
|
static ɵfac: i0.ɵɵFactoryDeclaration<AXNotificationComponent, never>;
|
39
39
|
static ɵcmp: i0.ɵɵComponentDeclaration<AXNotificationComponent, "ax-notification", never, {}, {}, never, never, false, never>;
|
@@ -6,7 +6,9 @@ export declare class AXNotificationService {
|
|
6
6
|
show(config: AXNotificationDisplayConfig): AXNotificationRef;
|
7
7
|
hideAll(): void;
|
8
8
|
private reposition;
|
9
|
+
private getRepositionPosition;
|
9
10
|
private getPosition;
|
11
|
+
private getPositionStrategy;
|
10
12
|
static ɵfac: i0.ɵɵFactoryDeclaration<AXNotificationService, never>;
|
11
13
|
static ɵprov: i0.ɵɵInjectableDeclaration<AXNotificationService>;
|
12
14
|
}
|
package/package.json
CHANGED
@@ -11,7 +11,7 @@ import * as i0 from "@angular/core";
|
|
11
11
|
*/
|
12
12
|
export declare class AXToastComponent extends MXBaseComponent implements OnInit {
|
13
13
|
config: AXToastData;
|
14
|
-
|
14
|
+
dialogRef: DialogRef<AXComponentCloseEvent>;
|
15
15
|
/** @ignore */
|
16
16
|
protected _toastWidth: number;
|
17
17
|
/** @ignore */
|
@@ -5,6 +5,11 @@ export declare class AXToastService {
|
|
5
5
|
private readonly scrollStrategyOptions;
|
6
6
|
private dialog;
|
7
7
|
private defaultConfig;
|
8
|
+
private activeToasts;
|
9
|
+
private reservedToasts;
|
10
|
+
private toastCounterElement;
|
11
|
+
private reserveCounter;
|
12
|
+
private moreToastsColor;
|
8
13
|
scrollStrategy: ScrollStrategy;
|
9
14
|
constructor(scrollStrategyOptions: ScrollStrategyOptions);
|
10
15
|
primary(content: string): void;
|
@@ -12,10 +17,13 @@ export declare class AXToastService {
|
|
12
17
|
success(content: string): void;
|
13
18
|
warning(content: string): void;
|
14
19
|
danger(content: string): void;
|
15
|
-
show(config: AXToastDisplayConfig): AXToastRef;
|
20
|
+
show(config: AXToastDisplayConfig): AXToastRef | void;
|
16
21
|
hideAll(): void;
|
22
|
+
private createReservedCounterToast;
|
17
23
|
private reposition;
|
24
|
+
private getRepositionPosition;
|
18
25
|
private getPosition;
|
26
|
+
private getPositionStrategy;
|
19
27
|
static ɵfac: i0.ɵɵFactoryDeclaration<AXToastService, never>;
|
20
28
|
static ɵprov: i0.ɵɵInjectableDeclaration<AXToastService>;
|
21
29
|
}
|