@acorex/components 18.12.20 → 18.12.22
Sign up to get free protection for your applications and to get access to all the features.
- package/conversation/lib/conversation-messages/conversation-message-audio/conversation-message-audio.component.d.ts +11 -32
- package/data-table/lib/columns/row-command-column.component.d.ts +3 -3
- package/drawer/lib/drawer/drawer-container/drawer-container.component.d.ts +2 -3
- package/drawer/lib/drawer/drawer-item/drawer.component.d.ts +7 -8
- package/esm2022/comment/lib/comment-item/comment-item.component.mjs +3 -3
- package/esm2022/conversation/lib/conversation-messages/conversation-message-audio/conversation-message-audio.component.mjs +30 -58
- package/esm2022/conversation/lib/services/conversation.service.mjs +1 -1
- package/esm2022/data-table/lib/columns/row-command-column.component.mjs +20 -10
- package/esm2022/datetime-box/lib/datetime-box.component.mjs +3 -3
- package/esm2022/drawer/lib/drawer/drawer-container/drawer-container.component.mjs +5 -7
- package/esm2022/drawer/lib/drawer/drawer-item/drawer.component.mjs +22 -26
- package/esm2022/image-editor/lib/image-editor-tools/image-editor-color-picker/image-editor-color-picker.component.mjs +6 -16
- package/esm2022/image-editor/lib/image-editor-tools/image-editor-crop/image-editor-crop.component.mjs +4 -3
- package/esm2022/image-editor/lib/image-editor-tools/image-editor-pen-mode-changer/image-editor-pen-mode-changer.component.mjs +4 -3
- package/esm2022/image-editor/lib/image-editor.module.mjs +8 -5
- package/esm2022/json-viewer/acorex-components-json-viewer.mjs +5 -0
- package/esm2022/json-viewer/index.mjs +3 -0
- package/esm2022/json-viewer/lib/json-viewer/json-viewer.component.mjs +36 -0
- package/esm2022/json-viewer/lib/json-viewer.module.mjs +23 -0
- package/esm2022/media-viewer/lib/media-viewer-thumbnail/media-viewer-thumbnail.component.mjs +5 -4
- package/esm2022/menu/lib/menu.module.mjs +2 -2
- package/esm2022/paint/lib/paint/paint-tools/paint-color-picker/paint-color-picker.component.mjs +5 -15
- package/esm2022/paint/lib/paint/paint-tools/paint-pen-mode-changer/paint-pen-mode-changer.component.mjs +4 -3
- package/esm2022/paint/lib/paint.module.mjs +8 -5
- package/esm2022/phone-box/lib/phone-box.component.mjs +26 -22
- package/esm2022/range-slider/lib/range-slider.component.mjs +7 -7
- package/esm2022/slider/lib/slider.component.mjs +2 -2
- package/esm2022/step-wizard/lib/step-wizard-item/step-wizard-item.component.mjs +2 -2
- package/esm2022/text-box/lib/text-box.component.mjs +5 -4
- package/fesm2022/acorex-components-action-sheet.mjs.map +1 -1
- package/fesm2022/acorex-components-alert.mjs.map +1 -1
- package/fesm2022/acorex-components-audio-wave.mjs.map +1 -1
- package/fesm2022/acorex-components-avatar.mjs.map +1 -1
- package/fesm2022/acorex-components-badge.mjs.map +1 -1
- package/fesm2022/acorex-components-bottom-navigation.mjs.map +1 -1
- package/fesm2022/acorex-components-breadcrumbs.mjs.map +1 -1
- package/fesm2022/acorex-components-button-group.mjs.map +1 -1
- package/fesm2022/acorex-components-button.mjs.map +1 -1
- package/fesm2022/acorex-components-calendar.mjs.map +1 -1
- package/fesm2022/acorex-components-check-box.mjs.map +1 -1
- package/fesm2022/acorex-components-chips.mjs.map +1 -1
- package/fesm2022/acorex-components-circular-progress.mjs.map +1 -1
- package/fesm2022/acorex-components-collapse.mjs.map +1 -1
- package/fesm2022/acorex-components-color-box.mjs.map +1 -1
- package/fesm2022/acorex-components-color-palette.mjs.map +1 -1
- package/fesm2022/acorex-components-comment.mjs +2 -2
- package/fesm2022/acorex-components-comment.mjs.map +1 -1
- package/fesm2022/acorex-components-common.mjs.map +1 -1
- package/fesm2022/acorex-components-conversation.mjs +29 -57
- package/fesm2022/acorex-components-conversation.mjs.map +1 -1
- package/fesm2022/acorex-components-data-pager.mjs.map +1 -1
- package/fesm2022/acorex-components-data-table.mjs +19 -9
- package/fesm2022/acorex-components-data-table.mjs.map +1 -1
- package/fesm2022/acorex-components-datetime-box.mjs +2 -2
- package/fesm2022/acorex-components-datetime-box.mjs.map +1 -1
- package/fesm2022/acorex-components-datetime-input.mjs.map +1 -1
- package/fesm2022/acorex-components-datetime-picker.mjs.map +1 -1
- package/fesm2022/acorex-components-decorators.mjs.map +1 -1
- package/fesm2022/acorex-components-dialog.mjs.map +1 -1
- package/fesm2022/acorex-components-drawer.mjs +25 -31
- package/fesm2022/acorex-components-drawer.mjs.map +1 -1
- package/fesm2022/acorex-components-dropdown-button.mjs.map +1 -1
- package/fesm2022/acorex-components-dropdown.mjs.map +1 -1
- package/fesm2022/acorex-components-form.mjs.map +1 -1
- package/fesm2022/acorex-components-image-editor.mjs +19 -23
- package/fesm2022/acorex-components-image-editor.mjs.map +1 -1
- package/fesm2022/acorex-components-image.mjs.map +1 -1
- package/fesm2022/acorex-components-json-viewer.mjs +63 -0
- package/fesm2022/acorex-components-json-viewer.mjs.map +1 -0
- package/fesm2022/acorex-components-label.mjs.map +1 -1
- package/fesm2022/acorex-components-list.mjs.map +1 -1
- package/fesm2022/acorex-components-loading-dialog.mjs.map +1 -1
- package/fesm2022/acorex-components-loading.mjs.map +1 -1
- package/fesm2022/acorex-components-map.mjs.map +1 -1
- package/fesm2022/acorex-components-media-viewer.mjs +4 -3
- package/fesm2022/acorex-components-media-viewer.mjs.map +1 -1
- package/fesm2022/acorex-components-menu.mjs.map +1 -1
- package/fesm2022/acorex-components-nav.mjs.map +1 -1
- package/fesm2022/acorex-components-navbar.mjs.map +1 -1
- package/fesm2022/acorex-components-notification.mjs.map +1 -1
- package/fesm2022/acorex-components-number-box.mjs.map +1 -1
- package/fesm2022/acorex-components-otp.mjs.map +1 -1
- package/fesm2022/acorex-components-page.mjs.map +1 -1
- package/fesm2022/acorex-components-paint.mjs +14 -18
- package/fesm2022/acorex-components-paint.mjs.map +1 -1
- package/fesm2022/acorex-components-password-box.mjs.map +1 -1
- package/fesm2022/acorex-components-phone-box.mjs +26 -22
- package/fesm2022/acorex-components-phone-box.mjs.map +1 -1
- package/fesm2022/acorex-components-picker.mjs.map +1 -1
- package/fesm2022/acorex-components-popover.mjs.map +1 -1
- package/fesm2022/acorex-components-popup.mjs.map +1 -1
- package/fesm2022/acorex-components-progress-bar.mjs.map +1 -1
- package/fesm2022/acorex-components-qrcode.mjs.map +1 -1
- package/fesm2022/acorex-components-radio.mjs.map +1 -1
- package/fesm2022/acorex-components-range-slider.mjs +6 -6
- package/fesm2022/acorex-components-range-slider.mjs.map +1 -1
- package/fesm2022/acorex-components-rate-picker.mjs.map +1 -1
- package/fesm2022/acorex-components-result.mjs.map +1 -1
- package/fesm2022/acorex-components-routing-progress.mjs.map +1 -1
- package/fesm2022/acorex-components-scheduler.mjs.map +1 -1
- package/fesm2022/acorex-components-scss.mjs.map +1 -1
- package/fesm2022/acorex-components-search-box.mjs.map +1 -1
- package/fesm2022/acorex-components-select-box.mjs.map +1 -1
- package/fesm2022/acorex-components-selection-list.mjs.map +1 -1
- package/fesm2022/acorex-components-side-menu.mjs.map +1 -1
- package/fesm2022/acorex-components-skeleton.mjs.map +1 -1
- package/fesm2022/acorex-components-slider.mjs +2 -2
- package/fesm2022/acorex-components-slider.mjs.map +1 -1
- package/fesm2022/acorex-components-step-wizard.mjs +2 -2
- package/fesm2022/acorex-components-step-wizard.mjs.map +1 -1
- package/fesm2022/acorex-components-switch.mjs.map +1 -1
- package/fesm2022/acorex-components-tabs.mjs.map +1 -1
- package/fesm2022/acorex-components-tag.mjs.map +1 -1
- package/fesm2022/acorex-components-text-area.mjs.map +1 -1
- package/fesm2022/acorex-components-text-box.mjs +4 -3
- package/fesm2022/acorex-components-text-box.mjs.map +1 -1
- package/fesm2022/acorex-components-time-line.mjs.map +1 -1
- package/fesm2022/acorex-components-toast.mjs.map +1 -1
- package/fesm2022/acorex-components-tooltip.mjs.map +1 -1
- package/fesm2022/acorex-components-uploader.mjs.map +1 -1
- package/fesm2022/acorex-components-wysiwyg.mjs.map +1 -1
- package/image-editor/lib/image-editor-tools/image-editor-color-picker/image-editor-color-picker.component.d.ts +0 -10
- package/image-editor/lib/image-editor.module.d.ts +3 -2
- package/json-viewer/README.md +3 -0
- package/json-viewer/index.d.ts +2 -0
- package/json-viewer/lib/json-viewer/json-viewer.component.d.ts +11 -0
- package/json-viewer/lib/json-viewer.module.d.ts +10 -0
- package/media-viewer/lib/media-viewer-thumbnail/media-viewer-thumbnail.component.d.ts +1 -1
- package/package.json +57 -51
- package/paint/lib/paint/paint-tools/paint-color-picker/paint-color-picker.component.d.ts +0 -10
- package/paint/lib/paint.module.d.ts +3 -2
- package/phone-box/lib/phone-box.component.d.ts +24 -22
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"acorex-components-picker.mjs","sources":["../../../../libs/components/picker/src/lib/picker-column.directive.ts","../../../../libs/components/picker/src/lib/picker.component.ts","../../../../libs/components/picker/src/lib/picker.component.html","../../../../libs/components/picker/src/lib/picker.module.ts","../../../../libs/components/picker/src/acorex-components-picker.ts"],"sourcesContent":["import { MXValueComponent } from '@acorex/components/common';\nimport { Directive, EventEmitter, Input, Output, forwardRef } from '@angular/core';\nimport { NG_VALUE_ACCESSOR } from '@angular/forms';\n\n@Directive({\n selector: 'ax-picker-column',\n inputs: ['disabled', 'readonly', 'readonlyChange', 'disabledChange'],\n outputs: ['onValueChanged'],\n providers: [\n {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => AXPickerColumnDirective),\n multi: true,\n },\n ],\n})\nexport class AXPickerColumnDirective extends MXValueComponent {\n @Input()\n valueField = 'id';\n\n @Input()\n textField = 'text';\n\n @Input()\n public title: string;\n @Input()\n public step = 1;\n\n @Output()\n itemsChange: EventEmitter<unknown[]> = new EventEmitter<unknown[]>();\n\n private _items: unknown[];\n @Input()\n public get items(): unknown[] {\n return this._items;\n }\n public set items(v: unknown[]) {\n this._items = v;\n this.itemsChange.emit(v);\n }\n\n override internalSetValue(v) {\n if (v == null) return v;\n else if (typeof v == 'object') {\n return this.items.find((c) => c[this.valueField] == v[this.valueField]);\n } else {\n return this.items.find((c) => c[this.valueField] == v);\n }\n }\n}\n","import { MXBaseComponent } from '@acorex/components/common';\nimport { AXDrawingUtil, AXUnsubscriber } from '@acorex/core/utils';\nimport {\n AfterContentInit,\n ChangeDetectionStrategy,\n Component,\n ContentChildren,\n NgZone,\n OnDestroy,\n QueryList,\n ViewEncapsulation,\n inject,\n} from '@angular/core';\nimport { startWith } from 'rxjs';\nimport { AXPickerColumnDirective } from './picker-column.directive';\n\n/**\n * @category Components\n * A picker component with OnPush change detection and no encapsulation.\n */\n@Component({\n selector: 'ax-picker',\n templateUrl: './picker.component.html',\n styleUrls: ['./picker.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n providers: [AXUnsubscriber],\n})\nexport class AXPickerComponent extends MXBaseComponent implements AfterContentInit, OnDestroy {\n\n /** @ignore */\n @ContentChildren(AXPickerColumnDirective, { emitDistinctChangesOnly: true })\n\n /** @ignore */\n protected _columns: QueryList<AXPickerColumnDirective> = {} as QueryList<AXPickerColumnDirective>;\n\n /** @ignore */\n private _itemHeight = this._calcItemheight();\n\n /** @ignore */\n private _htmlColumns: HTMLDivElement[];\n\n /** @ignore */\n private _dragging = false;\n\n /** @ignore */\n private _previousY: number;\n\n /** @ignore */\n private _currentList: HTMLDivElement;\n\n /** @ignore */\n protected _unsubscriber: AXUnsubscriber = inject(AXUnsubscriber);\n\n /** @ignore */\n protected _zone: NgZone = inject(NgZone);\n\n /** @ignore */\n ngAfterContentInit() {\n this._columns.changes\n .pipe(this._unsubscriber.takeUntilDestroy)\n .pipe(startWith(undefined))\n .subscribe(() => {\n this._setHeights();\n this.cdr.detectChanges();\n this._bindEvents();\n });\n }\n\n /** @ignore */\n ngOnDestroy() {\n this._removeEvents();\n }\n\n /** @ignore */\n private _setHeights() {\n this._itemHeight = this._calcItemheight();\n setTimeout(() => {\n const val = this.getHostElement().clientHeight - this.getHostElement().querySelector('.ax-header').clientHeight;\n this.getHostElement().style.setProperty('--ax-content-height', `${val}px`);\n }, 50);\n }\n\n /** @ignore */\n private _calcItemheight(): number {\n const rem = window.getComputedStyle(document.documentElement, null).getPropertyValue('--ax-size-default');\n return AXDrawingUtil.convertRemToPixels(Number(rem?.replace('rem', '') ?? 0));\n }\n\n /** @ignore */\n private _bindEvents(): void {\n this._removeEvents();\n //\n this._htmlColumns = Array.from(this.getHostElement().querySelectorAll<HTMLDivElement>('.ax-picker-col .ax-content'));\n this._columns.forEach((c) => {\n c.onValueChanged.pipe(this._unsubscriber.takeUntilDestroy).subscribe(() => {\n this._detectSelectedItemsByValue();\n });\n });\n\n this._htmlColumns.forEach((col, index) => {\n col['column'] = this._columns.get(index);\n col.addEventListener('wheel', this._handleMouseWeel.bind(this), {\n passive: false,\n });\n //\n col.addEventListener('touchstart', this._handleTouchStart.bind(this), {\n passive: false,\n });\n //col.addEventListener(\"mousedown\", this._handleTouchStart.bind(this), { passive: false });\n //\n col.addEventListener('touchmove', this._handleTouchMove.bind(this), {\n passive: false,\n });\n //col.addEventListener('mousemove', this._handleTouchMove.bind(this), { passive: false })\n //\n col.addEventListener('touchend', this._handleTouchEnd.bind(this), {\n passive: false,\n });\n //col.addEventListener('mouseup', this._handleTouchMove.bind(this), { passive: false })\n });\n }\n\n /** @ignore */\n private _removeEvents(): void {\n this._htmlColumns?.forEach((col) => {\n col.removeEventListener('wheel', this._handleMouseWeel.bind(this));\n //\n col.removeEventListener('touchstart', this._handleTouchStart.bind(this));\n //col.removeEventListener(\"mousedown\", this._handleTouchStart.bind(this));\n col.removeEventListener('touchmove', this._handleTouchMove.bind(this));\n //col.removeEventListener('mousemove', this._handleTouchMove.bind(this));\n //\n col.removeEventListener('touchend', this._handleTouchEnd.bind(this));\n //col.removeEventListener('mouseup', this._handleTouchEnd.bind(this));\n });\n }\n\n /** @ignore */\n _handleTouchStart(e: MouseEvent | TouchEvent) {\n e.preventDefault();\n e.stopPropagation();\n this._currentList = e.currentTarget as HTMLDivElement;\n this._previousY = e instanceof TouchEvent ? e.touches[0].clientY : e.clientY;\n }\n\n /** @ignore */\n private _handleTouchMove(e: MouseEvent | TouchEvent): void {\n this._dragging = true;\n e.preventDefault();\n e.stopPropagation();\n this._zone.runOutsideAngular(() => {\n if (this._currentList && this._dragging) {\n const clientY = e instanceof TouchEvent ? e.touches[0].clientY : e.clientY;\n const delta = clientY - this._previousY;\n this._previousY = clientY;\n if (Math.abs(delta) > 1) this._moveByDelta(this._currentList, -delta);\n }\n });\n }\n\n /** @ignore */\n private _handleTouchEnd(e: MouseEvent | TouchEvent): void {\n // simulate click\n const targetelement = e.target as HTMLElement;\n if (!this._dragging && targetelement.tagName == 'LI') {\n targetelement.click();\n }\n this._dragging = false;\n }\n\n /** @ignore */\n private _handleMouseWeel(e: WheelEvent): void {\n e.preventDefault();\n e.stopPropagation();\n this._moveByDelta(e.currentTarget as HTMLDivElement, e.deltaY);\n }\n\n /** @ignore */\n private _moveByDelta(col: HTMLDivElement, deltaY: number) {\n const column = col['column'] as AXPickerColumnDirective;\n if (column.readonly || column.disabled) return;\n let index = column.items.indexOf(column.value);\n index = deltaY < 0 ? index - column.step : index + column.step;\n if (index < 0) index = 0;\n if (index >= column.items.length) index = column.items.length - 1;\n column.commitValue(column.items[index], true);\n }\n\n /** @ignore */\n protected _handleItemClick(column: AXPickerColumnDirective, item: any) {\n if (column.readonly || column.disabled) return;\n column.commitValue(item, true);\n }\n\n /** @ignore */\n private _detectSelectedItemsByValue(): void {\n this._zone.runOutsideAngular(() => {\n this._htmlColumns.forEach((col) => {\n const column = col['column'] as AXPickerColumnDirective;\n const index = column.items.indexOf(column.value);\n col.querySelector('ul').style.transform = `translateY(${-index * this._itemHeight}px)`;\n this.cdr.markForCheck();\n });\n });\n }\n\n /**\n * Refreshes the component by setting heights and detecting selected items by value.\n */\n public refresh() {\n this._setHeights();\n this._detectSelectedItemsByValue();\n }\n}\n","<div class=\"ax-header\">\n @for(col of _columns; track $index){\n <div class=\"ax-picker-col\">\n <div class=\"ax-header\">\n {{ col.title }}\n </div>\n </div>\n }\n</div>\n<div class=\"ax-content\">\n <div class=\"ax-picker-window\"></div>\n @for(col of _columns; track $index){\n <div class=\"ax-picker-col\" [class.ax-state-disabled]=\"col.disabled\" [class.ax-state-readonly]=\"col.readonly\">\n <div class=\"ax-content\">\n <ul>\n @for(item of col.items; track $index){\n <li (click)=\"_handleItemClick(col, item)\"\n [class.ax-state-active]=\"col.value && col.value[col.valueField] === item[col.valueField]\"\n [class.ax-state-disabled]=\"col.disabled\" [class.ax-state-readonly]=\"col.readonly\">\n {{ item[col.textField] }}\n </li>\n }\n </ul>\n </div>\n </div>\n }\n\n</div>","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { AXPickerColumnDirective } from './picker-column.directive';\nimport { AXPickerComponent } from './picker.component';\n\nconst COMPONENT = [AXPickerComponent, AXPickerColumnDirective];\nconst MODULES = [CommonModule];\n\n@NgModule({\n declarations: [...COMPONENT],\n imports: [...MODULES],\n exports: [...COMPONENT],\n providers: [],\n})\nexport class AXPickerModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;AAgBM,MAAO,uBAAwB,SAAQ,gBAAgB,CAAA;AAZ7D,IAAA,WAAA,GAAA;;QAcE,IAAU,CAAA,UAAA,GAAG,IAAI,CAAC;QAGlB,IAAS,CAAA,SAAA,GAAG,MAAM,CAAC;QAKZ,IAAI,CAAA,IAAA,GAAG,CAAC,CAAC;AAGhB,QAAA,IAAA,CAAA,WAAW,GAA4B,IAAI,YAAY,EAAa,CAAC;AAoBtE,KAAA;AAjBC,IAAA,IACW,KAAK,GAAA;QACd,OAAO,IAAI,CAAC,MAAM,CAAC;KACpB;IACD,IAAW,KAAK,CAAC,CAAY,EAAA;AAC3B,QAAA,IAAI,CAAC,MAAM,GAAG,CAAC,CAAC;AAChB,QAAA,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;KAC1B;AAEQ,IAAA,gBAAgB,CAAC,CAAC,EAAA;QACzB,IAAI,CAAC,IAAI,IAAI;AAAE,YAAA,OAAO,CAAC,CAAC;AACnB,aAAA,IAAI,OAAO,CAAC,IAAI,QAAQ,EAAE;YAC7B,OAA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YAAY,EAAE,CAAC,GAAG,SAAS,CAAC;AAC5B,oBAAA,OAAO,EAAE,CAAC,GAAG,OAAO,CAAC;AACrB,oBAAA,OAAO,EAAE,CAAC,GAAG,SAAS,CAAC;AACvB,oBAAA,SAAS,EAAE,EAAE;AACd,iBAAA,CAAA;;;ACbD;;AAEG;;;;"}
|
1
|
+
{"version":3,"file":"acorex-components-picker.mjs","sources":["../../../../libs/components/picker/src/lib/picker-column.directive.ts","../../../../libs/components/picker/src/lib/picker.component.ts","../../../../libs/components/picker/src/lib/picker.component.html","../../../../libs/components/picker/src/lib/picker.module.ts","../../../../libs/components/picker/src/acorex-components-picker.ts"],"sourcesContent":["import { MXValueComponent } from '@acorex/components/common';\nimport { Directive, EventEmitter, Input, Output, forwardRef } from '@angular/core';\nimport { NG_VALUE_ACCESSOR } from '@angular/forms';\n\n@Directive({\n selector: 'ax-picker-column',\n inputs: ['disabled', 'readonly', 'readonlyChange', 'disabledChange'],\n outputs: ['onValueChanged'],\n providers: [\n {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => AXPickerColumnDirective),\n multi: true,\n },\n ],\n})\nexport class AXPickerColumnDirective extends MXValueComponent {\n @Input()\n valueField = 'id';\n\n @Input()\n textField = 'text';\n\n @Input()\n public title: string;\n @Input()\n public step = 1;\n\n @Output()\n itemsChange: EventEmitter<unknown[]> = new EventEmitter<unknown[]>();\n\n private _items: unknown[];\n @Input()\n public get items(): unknown[] {\n return this._items;\n }\n public set items(v: unknown[]) {\n this._items = v;\n this.itemsChange.emit(v);\n }\n\n override internalSetValue(v) {\n if (v == null) return v;\n else if (typeof v == 'object') {\n return this.items.find((c) => c[this.valueField] == v[this.valueField]);\n } else {\n return this.items.find((c) => c[this.valueField] == v);\n }\n }\n}\n","import { MXBaseComponent } from '@acorex/components/common';\nimport { AXDrawingUtil, AXUnsubscriber } from '@acorex/core/utils';\nimport {\n AfterContentInit,\n ChangeDetectionStrategy,\n Component,\n ContentChildren,\n NgZone,\n OnDestroy,\n QueryList,\n ViewEncapsulation,\n inject,\n} from '@angular/core';\nimport { startWith } from 'rxjs';\nimport { AXPickerColumnDirective } from './picker-column.directive';\n\n/**\n * @category Components\n * A picker component with OnPush change detection and no encapsulation.\n */\n@Component({\n selector: 'ax-picker',\n templateUrl: './picker.component.html',\n styleUrls: ['./picker.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n providers: [AXUnsubscriber],\n})\nexport class AXPickerComponent extends MXBaseComponent implements AfterContentInit, OnDestroy {\n\n /** @ignore */\n @ContentChildren(AXPickerColumnDirective, { emitDistinctChangesOnly: true })\n\n /** @ignore */\n protected _columns: QueryList<AXPickerColumnDirective> = {} as QueryList<AXPickerColumnDirective>;\n\n /** @ignore */\n private _itemHeight = this._calcItemheight();\n\n /** @ignore */\n private _htmlColumns: HTMLDivElement[];\n\n /** @ignore */\n private _dragging = false;\n\n /** @ignore */\n private _previousY: number;\n\n /** @ignore */\n private _currentList: HTMLDivElement;\n\n /** @ignore */\n protected _unsubscriber: AXUnsubscriber = inject(AXUnsubscriber);\n\n /** @ignore */\n protected _zone: NgZone = inject(NgZone);\n\n /** @ignore */\n ngAfterContentInit() {\n this._columns.changes\n .pipe(this._unsubscriber.takeUntilDestroy)\n .pipe(startWith(undefined))\n .subscribe(() => {\n this._setHeights();\n this.cdr.detectChanges();\n this._bindEvents();\n });\n }\n\n /** @ignore */\n ngOnDestroy() {\n this._removeEvents();\n }\n\n /** @ignore */\n private _setHeights() {\n this._itemHeight = this._calcItemheight();\n setTimeout(() => {\n const val = this.getHostElement().clientHeight - this.getHostElement().querySelector('.ax-header').clientHeight;\n this.getHostElement().style.setProperty('--ax-content-height', `${val}px`);\n }, 50);\n }\n\n /** @ignore */\n private _calcItemheight(): number {\n const rem = window.getComputedStyle(document.documentElement, null).getPropertyValue('--ax-size-default');\n return AXDrawingUtil.convertRemToPixels(Number(rem?.replace('rem', '') ?? 0));\n }\n\n /** @ignore */\n private _bindEvents(): void {\n this._removeEvents();\n //\n this._htmlColumns = Array.from(this.getHostElement().querySelectorAll<HTMLDivElement>('.ax-picker-col .ax-content'));\n this._columns.forEach((c) => {\n c.onValueChanged.pipe(this._unsubscriber.takeUntilDestroy).subscribe(() => {\n this._detectSelectedItemsByValue();\n });\n });\n\n this._htmlColumns.forEach((col, index) => {\n col['column'] = this._columns.get(index);\n col.addEventListener('wheel', this._handleMouseWeel.bind(this), {\n passive: false,\n });\n //\n col.addEventListener('touchstart', this._handleTouchStart.bind(this), {\n passive: false,\n });\n //col.addEventListener(\"mousedown\", this._handleTouchStart.bind(this), { passive: false });\n //\n col.addEventListener('touchmove', this._handleTouchMove.bind(this), {\n passive: false,\n });\n //col.addEventListener('mousemove', this._handleTouchMove.bind(this), { passive: false })\n //\n col.addEventListener('touchend', this._handleTouchEnd.bind(this), {\n passive: false,\n });\n //col.addEventListener('mouseup', this._handleTouchMove.bind(this), { passive: false })\n });\n }\n\n /** @ignore */\n private _removeEvents(): void {\n this._htmlColumns?.forEach((col) => {\n col.removeEventListener('wheel', this._handleMouseWeel.bind(this));\n //\n col.removeEventListener('touchstart', this._handleTouchStart.bind(this));\n //col.removeEventListener(\"mousedown\", this._handleTouchStart.bind(this));\n col.removeEventListener('touchmove', this._handleTouchMove.bind(this));\n //col.removeEventListener('mousemove', this._handleTouchMove.bind(this));\n //\n col.removeEventListener('touchend', this._handleTouchEnd.bind(this));\n //col.removeEventListener('mouseup', this._handleTouchEnd.bind(this));\n });\n }\n\n /** @ignore */\n _handleTouchStart(e: MouseEvent | TouchEvent) {\n e.preventDefault();\n e.stopPropagation();\n this._currentList = e.currentTarget as HTMLDivElement;\n this._previousY = e instanceof TouchEvent ? e.touches[0].clientY : e.clientY;\n }\n\n /** @ignore */\n private _handleTouchMove(e: MouseEvent | TouchEvent): void {\n this._dragging = true;\n e.preventDefault();\n e.stopPropagation();\n this._zone.runOutsideAngular(() => {\n if (this._currentList && this._dragging) {\n const clientY = e instanceof TouchEvent ? e.touches[0].clientY : e.clientY;\n const delta = clientY - this._previousY;\n this._previousY = clientY;\n if (Math.abs(delta) > 1) this._moveByDelta(this._currentList, -delta);\n }\n });\n }\n\n /** @ignore */\n private _handleTouchEnd(e: MouseEvent | TouchEvent): void {\n // simulate click\n const targetelement = e.target as HTMLElement;\n if (!this._dragging && targetelement.tagName == 'LI') {\n targetelement.click();\n }\n this._dragging = false;\n }\n\n /** @ignore */\n private _handleMouseWeel(e: WheelEvent): void {\n e.preventDefault();\n e.stopPropagation();\n this._moveByDelta(e.currentTarget as HTMLDivElement, e.deltaY);\n }\n\n /** @ignore */\n private _moveByDelta(col: HTMLDivElement, deltaY: number) {\n const column = col['column'] as AXPickerColumnDirective;\n if (column.readonly || column.disabled) return;\n let index = column.items.indexOf(column.value);\n index = deltaY < 0 ? index - column.step : index + column.step;\n if (index < 0) index = 0;\n if (index >= column.items.length) index = column.items.length - 1;\n column.commitValue(column.items[index], true);\n }\n\n /** @ignore */\n protected _handleItemClick(column: AXPickerColumnDirective, item: any) {\n if (column.readonly || column.disabled) return;\n column.commitValue(item, true);\n }\n\n /** @ignore */\n private _detectSelectedItemsByValue(): void {\n this._zone.runOutsideAngular(() => {\n this._htmlColumns.forEach((col) => {\n const column = col['column'] as AXPickerColumnDirective;\n const index = column.items.indexOf(column.value);\n col.querySelector('ul').style.transform = `translateY(${-index * this._itemHeight}px)`;\n this.cdr.markForCheck();\n });\n });\n }\n\n /**\n * Refreshes the component by setting heights and detecting selected items by value.\n */\n public refresh() {\n this._setHeights();\n this._detectSelectedItemsByValue();\n }\n}\n","<div class=\"ax-header\">\n @for(col of _columns; track $index){\n <div class=\"ax-picker-col\">\n <div class=\"ax-header\">\n {{ col.title }}\n </div>\n </div>\n }\n</div>\n<div class=\"ax-content\">\n <div class=\"ax-picker-window\"></div>\n @for(col of _columns; track $index){\n <div class=\"ax-picker-col\" [class.ax-state-disabled]=\"col.disabled\" [class.ax-state-readonly]=\"col.readonly\">\n <div class=\"ax-content\">\n <ul>\n @for(item of col.items; track $index){\n <li (click)=\"_handleItemClick(col, item)\"\n [class.ax-state-active]=\"col.value && col.value[col.valueField] === item[col.valueField]\"\n [class.ax-state-disabled]=\"col.disabled\" [class.ax-state-readonly]=\"col.readonly\">\n {{ item[col.textField] }}\n </li>\n }\n </ul>\n </div>\n </div>\n }\n\n</div>","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { AXPickerColumnDirective } from './picker-column.directive';\nimport { AXPickerComponent } from './picker.component';\n\nconst COMPONENT = [AXPickerComponent, AXPickerColumnDirective];\nconst MODULES = [CommonModule];\n\n@NgModule({\n declarations: [...COMPONENT],\n imports: [...MODULES],\n exports: [...COMPONENT],\n providers: [],\n})\nexport class AXPickerModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;AAgBM,MAAO,uBAAwB,SAAQ,gBAAgB,CAAA;AAZ7D,IAAA,WAAA,GAAA;;QAcE,IAAU,CAAA,UAAA,GAAG,IAAI;QAGjB,IAAS,CAAA,SAAA,GAAG,MAAM;QAKX,IAAI,CAAA,IAAA,GAAG,CAAC;AAGf,QAAA,IAAA,CAAA,WAAW,GAA4B,IAAI,YAAY,EAAa;AAoBrE;AAjBC,IAAA,IACW,KAAK,GAAA;QACd,OAAO,IAAI,CAAC,MAAM;;IAEpB,IAAW,KAAK,CAAC,CAAY,EAAA;AAC3B,QAAA,IAAI,CAAC,MAAM,GAAG,CAAC;AACf,QAAA,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,CAAC,CAAC;;AAGjB,IAAA,gBAAgB,CAAC,CAAC,EAAA;QACzB,IAAI,CAAC,IAAI,IAAI;AAAE,YAAA,OAAO,CAAC;AAClB,aAAA,IAAI,OAAO,CAAC,IAAI,QAAQ,EAAE;YAC7B,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC,UAAU,CAAC,IAAI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EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;+GAAd,cAAc,EAAA,YAAA,EAAA,CATR,iBAAiB,EAAE,uBAAuB,aAC5C,YAAY,CAAA,EAAA,OAAA,EAAA,CADV,iBAAiB,EAAE,uBAAuB,CAAA,EAAA,CAAA,CAAA;AAShD,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,cAAc,YAJZ,OAAO,CAAA,EAAA,CAAA,CAAA;;2FAIT,cAAc,EAAA,UAAA,EAAA,CAAA;kBAN1B,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;AACvB,oBAAA,SAAS,EAAE,EAAE;AACd,iBAAA;;;ACbD;;AAEG;;;;"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"acorex-components-popover.mjs","sources":["../../../../libs/components/popover/src/lib/popover.component.ts","../../../../libs/components/popover/src/lib/popover.component.html","../../../../libs/components/popover/src/lib/popover.module.ts","../../../../libs/components/popover/src/acorex-components-popover.ts"],"sourcesContent":["import {\n AXConnectedPosition,\n AXEvent,\n AXFocusableComponent,\n AXPlacementType,\n MXBaseComponent,\n convertToPlacement,\n} from '@acorex/components/common';\nimport { AXPlatform, isBrowser } from '@acorex/core/platform';\nimport { AXHtmlUtil } from '@acorex/core/utils';\nimport { Overlay, OverlayRef, PositionStrategy } from '@angular/cdk/overlay';\nimport { ComponentPortal, ComponentType, Portal, TemplatePortal } from '@angular/cdk/portal';\nimport {\n ChangeDetectionStrategy,\n Component,\n ComponentRef,\n ElementRef,\n EventEmitter,\n Input,\n Output,\n TemplateRef,\n ViewChild,\n ViewEncapsulation,\n inject,\n} from '@angular/core';\nimport { Subscription, delay, fromEvent } from 'rxjs';\n\nexport type AXPopoverOpenTrigger = 'manual' | 'click' | 'hover' | 'toggle';\n\nexport type AXPopoverCloseTrigger = 'manual' | 'clickOut' | 'leave';\n\n/**\n * @category Components\n * A popover component with custom encapsulation and change detection settings.\n */\n@Component({\n selector: 'ax-popover',\n templateUrl: './popover.component.html',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [{ provide: AXFocusableComponent, useExisting: AXPopoverComponent }],\n})\nexport class AXPopoverComponent extends MXBaseComponent {\n private platformService = inject(AXPlatform);\n\n /** @ignore */\n private _platform: AXPlatform = inject(AXPlatform);\n\n /** @ignore */\n private _overlay: Overlay = inject(Overlay);\n\n /** @ignore */\n private _overlayRef!: OverlayRef;\n\n /** @ignore */\n private _isMouseOverButton = false;\n\n /** @ignore */\n private _isMouseOverTooltip = false;\n\n /** @ignore */\n private _lastActiveElement: HTMLElement;\n\n /** @ignore */\n private _targetEvents: {\n mouseenter?: Subscription;\n mouseleave?: Subscription;\n click?: Subscription;\n } = {};\n\n /** @ignore */\n private _overlayEvents: {\n attach?: Subscription;\n detach?: Subscription;\n scroll?: Subscription;\n outside?: Subscription;\n } = {};\n\n //\n\n /** @ignore */\n private _offsetX = 0;\n\n /**\n * Gets or sets the horizontal offset and updates it accordingly.\n */\n @Input()\n\n /**\n * Gets the horizontal offset value.\n */\n public get offsetX(): number {\n return this._offsetX;\n }\n\n /**\n * Sets the horizontal offset and updates it with a callback.\n */\n public set offsetX(v: number) {\n this.setOption({\n name: 'offsetX',\n value: v,\n afterCallback: () => {\n this.updateOffset();\n },\n });\n }\n //\n\n /** @ignore */\n private _offsetY = 0;\n\n /**\n * Vertical offset with update callback.\n */\n @Input()\n\n /**\n * Gets the vertical offset of the component.\n */\n public get offsetY(): number {\n return this._offsetY;\n }\n\n /**\n * Sets the vertical offset and updates the component position.\n */\n public set offsetY(v: number) {\n this.setOption({\n name: 'offsetY',\n value: v,\n afterCallback: () => {\n this.updateOffset();\n },\n });\n }\n\n //\n\n /** @ignore */\n private _target!: HTMLElement;\n\n /**\n * Gets or sets the target element, supporting HTMLElement, ElementRef, or MXBaseComponent.\n */\n @Input()\n\n /**\n * Gets the current target element.\n */\n public get target(): HTMLElement | ElementRef | MXBaseComponent {\n return this._target;\n }\n\n /**\n * Sets the target element and updates event bindings.\n */\n public set target(v: HTMLElement | ElementRef | MXBaseComponent) {\n this.removeTargetEvents();\n if (v instanceof HTMLElement) this._target = v;\n else if (v instanceof ElementRef) this._target = v.nativeElement;\n else if (typeof v?.getHostElement == 'function') this._target = v.getHostElement();\n //\n this.bindTargetEvents();\n }\n //\n\n /** @ignore */\n private _defautPlacements: AXConnectedPosition[] = convertToPlacement('bottom-start');\n\n /** @ignore */\n private _placements: AXConnectedPosition[] = [...this._defautPlacements];\n\n /** @ignore */\n private _placement: AXPlacementType = this._placements;\n\n /**\n * Gets or sets the component's placement and updates position settings.\n */\n @Input()\n\n /**\n * Gets the current placement of the component.\n */\n public get placement(): AXPlacementType {\n return this._placement;\n }\n\n /**\n * Sets the component's placement and updates its position settings.\n */\n public set placement(v: AXPlacementType) {\n this.setOption({\n name: 'placement',\n value: v,\n afterCallback: (o, n) => {\n const converted = convertToPlacement(n);\n this._placements = converted.length ? converted : this._defautPlacements;\n this.updateOffset();\n this.updatePositionStrategy();\n },\n });\n }\n //\n\n /** @ignore */\n private _portal: Portal<unknown>;\n\n /** @ignore */\n private _componentRef: ComponentRef<unknown>;\n\n /**\n * Gets the reference to the component.\n */\n public get componentRef(): ComponentRef<unknown> {\n return this._componentRef;\n }\n\n /**\n * Holds the context data for the component.\n */\n public context: unknown;\n\n //\n\n /** @ignore */\n @ViewChild('baseTemplate', { static: true })\n _baseTemplate: TemplateRef<unknown>;\n //\n\n /**\n * Defines the content to be displayed, which can be a template or a component.\n */\n @Input()\n content: TemplateRef<unknown> | ComponentType<unknown>;\n //\n\n /** @ignore */\n private _openOn: AXPopoverOpenTrigger = 'toggle';\n\n /**\n * Gets or sets the trigger for opening the popover and updates target events.\n */\n @Input()\n\n /**\n * Gets the trigger for opening the popover.\n */\n public get openOn(): AXPopoverOpenTrigger {\n return this._openOn;\n }\n\n /**\n * Sets the trigger for opening the popover and updates target events.\n */\n public set openOn(v: AXPopoverOpenTrigger) {\n this.setOption({\n name: 'openOn',\n value: v,\n afterCallback: () => {\n this.bindTargetEvents();\n },\n });\n }\n //\n\n /** @ignore */\n private _closeOn: AXPopoverCloseTrigger = 'clickOut';\n\n /**\n * Gets or sets the trigger for closing the popover.\n */\n @Input()\n public get closeOn(): AXPopoverCloseTrigger {\n return this._closeOn;\n }\n\n /**\n * Sets the trigger for closing the popover and rebinds target events.\n * @param v\n */\n public set closeOn(v: AXPopoverCloseTrigger) {\n this.setOption({\n name: 'closeOn',\n value: v,\n afterCallback: () => {\n this.bindTargetEvents();\n },\n });\n }\n\n //\n\n /**\n * Determines if a backdrop should be displayed behind the popover.\n */\n @Input()\n hasBackdrop = false;\n //\n\n /**\n * Delay in milliseconds before the popover opens after a trigger event.\n */\n @Input()\n openAfter = 200;\n\n /**\n * Delay in milliseconds before the popover closes after a trigger event.\n */\n @Input()\n closeAfter = 200;\n\n /**\n * CSS class to apply to the backdrop element.\n */\n @Input()\n backdropClass: string;\n\n /**\n * Enables or disables adaptivity.\n */\n @Input()\n adaptivityEnabled = false;\n //\n\n /**\n * Emits when the component is opened.\n * @event\n */\n @Output()\n onOpened: EventEmitter<AXEvent> = new EventEmitter<AXEvent>();\n\n /**\n * Emits when the component is closed.\n * @event\n */\n @Output()\n onClosed: EventEmitter<AXEvent> = new EventEmitter<AXEvent>();\n\n /** @ignore */\n private _emitOnOpenedEvent() {\n this.onOpened.emit({\n component: this,\n htmlElement: this.getHostElement(),\n });\n }\n\n /** @ignore */\n private _emitOnClosedEvent() {\n this.onClosed.emit({\n component: this,\n htmlElement: this.getHostElement(),\n });\n }\n //\n\n /** @ignore */\n protected _handleMouseEnter(e: MouseEvent) {\n this._isMouseOverTooltip = true;\n }\n\n /** @ignore */\n protected _handleMouseLeave(e: MouseEvent) {\n this._isMouseOverTooltip = false;\n setTimeout(() => {\n if (!this._isMouseOverButton && this.closeOn == 'leave') {\n this.close();\n }\n }, 250);\n }\n\n /** @ignore */\n private removeTargetEvents(): void {\n Object.entries(this._targetEvents).forEach((e) => {\n e[1].unsubscribe();\n });\n }\n\n /** @ignore */\n private bindTargetEvents() {\n this.removeTargetEvents();\n if (!this._target) return;\n const targetMouseEnter$ = fromEvent(this._target, 'mouseenter');\n const targetMouseLeave$ = fromEvent(this._target, 'mouseleave');\n\n if (this.openOn == 'hover') {\n this._targetEvents.mouseenter = targetMouseEnter$.pipe(delay(this.openAfter)).subscribe(() => {\n this._isMouseOverButton = true;\n this.open();\n });\n }\n\n if (this.closeOn == 'leave') {\n this._targetEvents.mouseleave = targetMouseLeave$.pipe(delay(this.closeAfter)).subscribe(() => {\n this._isMouseOverButton = false;\n if (!this._isMouseOverTooltip) {\n this.close();\n }\n });\n }\n\n if (this.openOn === 'click' || this.openOn === 'toggle') {\n const click$ = fromEvent<MouseEvent>(this._target, 'click');\n this._targetEvents.click = click$.subscribe((e) => {\n this.openOn == 'toggle' ? this.toggle() : this.open();\n });\n }\n }\n //\n\n /** @ignore */\n private bindOverlayEvents() {\n this.removeOverlayEvents();\n this._overlayEvents.attach = this._overlayRef.attachments().subscribe(() => {\n if (this.openOn == 'hover') {\n this._overlayRef.overlayElement.addEventListener('mouseenter', this._handleMouseEnter.bind(this));\n }\n if (this.closeOn == 'leave') {\n this._overlayRef.overlayElement.addEventListener('mouseleave', this._handleMouseLeave.bind(this));\n }\n //\n this._overlayEvents.outside = this._overlayRef._outsidePointerEvents.subscribe((e: MouseEvent) => {\n const el = e.target as HTMLElement;\n if (\n this.closeOn == 'clickOut' &&\n this.isOpen &&\n !this._target.contains(el) &&\n !this._overlayRef?.overlayElement?.contains(el)\n ) {\n this.close();\n }\n });\n //\n\n this._overlayEvents.scroll = this._platform.scroll.subscribe((c) => {\n //__axContext__\n const el = c.nativeEvent.target as HTMLElement;\n if (!this.isActionsheetStyle) {\n if (el == (document as any)) {\n this.close();\n return;\n }\n if (\n el?.closest &&\n !el.closest('.ax-overlay-pane') &&\n !this._target.contains(el) &&\n !this._overlayRef?.overlayElement?.contains(el)\n ) {\n this.close();\n }\n }\n });\n });\n }\n\n /** @ignore */\n private removeOverlayEvents() {\n this._overlayRef?.overlayElement.removeEventListener('mouseenter', this._handleMouseEnter.bind(this));\n this._overlayRef?.overlayElement.addEventListener('mouseleave', this._handleMouseLeave.bind(this));\n Object.entries(this._overlayEvents).forEach((e) => {\n e[1].unsubscribe();\n });\n }\n\n //\n /**\n * Toggles the component's open state.\n */\n toggle() {\n this.isOpen ? this.close() : this.open();\n }\n\n //\n /**\n * Closes the component if it's open, detaches the overlay, restores focus, and emits the closed event.\n */\n close() {\n if (!this.isOpen) {\n return;\n }\n this._overlayRef?.detach();\n this.restoreFocus();\n this._emitOnClosedEvent();\n }\n\n //\n /**\n * Opens the component if it's not already open, saves focus, opens the overlay, and emits the opened event.\n */\n open() {\n if (this.isOpen) {\n return;\n }\n this.saveFocus();\n this.openOverlayInternal();\n this._emitOnOpenedEvent();\n }\n\n /** @ignore */\n private saveFocus() {\n if (isBrowser()) {\n this._lastActiveElement = document.activeElement as HTMLElement;\n }\n }\n\n /** @ignore */\n private restoreFocus() {\n if (this._lastActiveElement?.focus) {\n this._lastActiveElement.focus();\n }\n }\n\n /** @ignore */\n private openOverlayInternal() {\n const targetRef = this._target;\n if (!targetRef) return;\n\n //if (!this._overlayRef) {\n if (this.isActionsheetStyle) {\n this._overlayRef = this._overlay.create({\n positionStrategy: this._overlay.position().global().bottom().centerHorizontally(),\n disposeOnNavigation: true,\n scrollStrategy: this._overlay.scrollStrategies.block(),\n panelClass: ['ax-actionsheet-base', 'ax-animate-slideInUp', 'ax-animate-faster'],\n hasBackdrop: true,\n width: '100%',\n });\n } else {\n this._overlayRef = this._overlay.create({\n positionStrategy: this._overlay\n .position()\n .flexibleConnectedTo(targetRef)\n .withPositions(this._placements)\n .withPush(false),\n scrollStrategy: this._overlay.scrollStrategies.noop(),\n disposeOnNavigation: true,\n panelClass: ['ax-animate-fadeIn', 'ax-animate-faster'],\n maxHeight: 'unset',\n hasBackdrop: this.hasBackdrop,\n backdropClass: [this.backdropClass || 'cdk-overlay-transparent-backdrop'],\n direction: AXHtmlUtil.isRtl(this.getHostElement()) ? 'rtl' : 'ltr',\n });\n // this._overlayRef.setDirection()\n }\n\n //\n this.bindOverlayEvents();\n //}\n //\n if (this.content instanceof TemplateRef) {\n this._portal = new TemplatePortal(this.content, this.getViewContainer(), {\n $implicit: this.context,\n ref: this,\n });\n this._overlayRef?.attach(this._portal);\n } else if (typeof this.content === 'function') {\n this._portal = new ComponentPortal(this.content);\n this._componentRef = this._overlayRef?.attach(this._portal);\n Object.assign(this._componentRef.instance, this.context);\n } else {\n this._portal = new TemplatePortal(this._baseTemplate, this.getViewContainer(), {\n $implicit: this.context,\n ref: this,\n });\n this._overlayRef?.attach(this._portal);\n }\n }\n\n /**\n * Checks if the overlay is currently open.\n * @returns {boolean}\n */\n get isOpen(): boolean {\n return this._overlayRef ? this._overlayRef.hasAttached() : false;\n }\n\n /**\n * Determines if the actionsheet style should be applied.\n * @returns {boolean}\n */\n get isActionsheetStyle(): boolean {\n return this._platform.is('SM') && this.adaptivityEnabled;\n }\n\n /** @ignore */\n private updatePositionStrategy(): void {\n const targetRef = this._target;\n if (!targetRef) return;\n let strategy: PositionStrategy;\n if (this.isActionsheetStyle) {\n strategy = this._overlay.position().global().bottom().centerHorizontally();\n } else {\n strategy = this._overlay\n .position()\n .flexibleConnectedTo(targetRef)\n .withPositions(this._placements)\n .withPush(false);\n }\n this._overlayRef?.updatePositionStrategy(strategy);\n }\n\n /** @ignore */\n private updateOffset() {\n this._placements?.forEach((p) => {\n if (this.offsetY != null) p.offsetY = this.offsetY;\n if (this.offsetX != null) p.offsetX = this.offsetX;\n });\n }\n\n /**\n * Updates the position of the overlay and focuses on it.\n */\n public updatePosition(): void {\n this._overlayRef?.updatePosition();\n this.focus();\n }\n\n /**\n * Focuses the overlay element.\n */\n public focus(): void {\n //TODO: need this??\n }\n //\n\n protected override ngOnInit(): void {\n super.ngOnInit();\n // this.platformService.directionChange.subscribe((c) => {\n // this.isRtl = c.data == 'rtl';\n // });\n }\n\n /** @ignore */\n ngOnDestroy(): void {\n this.removeTargetEvents();\n this.removeOverlayEvents();\n this._overlayRef?.detach();\n this._overlayRef?.dispose();\n }\n}\n","<ng-template #baseTemplate>\n <ng-content></ng-content>\n</ng-template>","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { AXPopoverComponent } from './popover.component';\n\n@NgModule({\n declarations: [AXPopoverComponent],\n imports: [CommonModule],\n exports: [AXPopoverComponent],\n providers: [],\n})\nexport class AXPopoverModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;AA+BA;;;AAGG;AAQG,MAAO,kBAAmB,SAAQ,eAAe,CAAA;AAPvD,IAAA,WAAA,GAAA;;AAQU,QAAA,IAAA,CAAA,eAAe,GAAG,MAAM,CAAC,UAAU,CAAC,CAAC;;AAGrC,QAAA,IAAA,CAAA,SAAS,GAAe,MAAM,CAAC,UAAU,CAAC,CAAC;;AAG3C,QAAA,IAAA,CAAA,QAAQ,GAAY,MAAM,CAAC,OAAO,CAAC,CAAC;;QAMpC,IAAkB,CAAA,kBAAA,GAAG,KAAK,CAAC;;QAG3B,IAAmB,CAAA,mBAAA,GAAG,KAAK,CAAC;;QAM5B,IAAa,CAAA,aAAA,GAIjB,EAAE,CAAC;;QAGC,IAAc,CAAA,cAAA,GAKlB,EAAE,CAAC;;;QAKC,IAAQ,CAAA,QAAA,GAAG,CAAC,CAAC;;;QA6Bb,IAAQ,CAAA,QAAA,GAAG,CAAC,CAAC;;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A,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,eAAe,YAJhB,YAAY,CAAA,EAAA,CAAA,CAAA,EAAA;;2FAIX,eAAe,EAAA,UAAA,EAAA,CAAA;kBAN3B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,YAAY,EAAE,CAAC,kBAAkB,CAAC;oBAClC,OAAO,EAAE,CAAC,YAAY,CAAC;oBACvB,OAAO,EAAE,CAAC,kBAAkB,CAAC;AAC7B,oBAAA,SAAS,EAAE,EAAE;AACd,iBAAA,CAAA;;;ACTD;;AAEG;;;;"}
|
1
|
+
{"version":3,"file":"acorex-components-popover.mjs","sources":["../../../../libs/components/popover/src/lib/popover.component.ts","../../../../libs/components/popover/src/lib/popover.component.html","../../../../libs/components/popover/src/lib/popover.module.ts","../../../../libs/components/popover/src/acorex-components-popover.ts"],"sourcesContent":["import {\n AXConnectedPosition,\n AXEvent,\n AXFocusableComponent,\n AXPlacementType,\n MXBaseComponent,\n convertToPlacement,\n} from '@acorex/components/common';\nimport { AXPlatform, isBrowser } from '@acorex/core/platform';\nimport { AXHtmlUtil } from '@acorex/core/utils';\nimport { Overlay, OverlayRef, PositionStrategy } from '@angular/cdk/overlay';\nimport { ComponentPortal, ComponentType, Portal, TemplatePortal } from '@angular/cdk/portal';\nimport {\n ChangeDetectionStrategy,\n Component,\n ComponentRef,\n ElementRef,\n EventEmitter,\n Input,\n Output,\n TemplateRef,\n ViewChild,\n ViewEncapsulation,\n inject,\n} from '@angular/core';\nimport { Subscription, delay, fromEvent } from 'rxjs';\n\nexport type AXPopoverOpenTrigger = 'manual' | 'click' | 'hover' | 'toggle';\n\nexport type AXPopoverCloseTrigger = 'manual' | 'clickOut' | 'leave';\n\n/**\n * @category Components\n * A popover component with custom encapsulation and change detection settings.\n */\n@Component({\n selector: 'ax-popover',\n templateUrl: './popover.component.html',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [{ provide: AXFocusableComponent, useExisting: AXPopoverComponent }],\n})\nexport class AXPopoverComponent extends MXBaseComponent {\n private platformService = inject(AXPlatform);\n\n /** @ignore */\n private _platform: AXPlatform = inject(AXPlatform);\n\n /** @ignore */\n private _overlay: Overlay = inject(Overlay);\n\n /** @ignore */\n private _overlayRef!: OverlayRef;\n\n /** @ignore */\n private _isMouseOverButton = false;\n\n /** @ignore */\n private _isMouseOverTooltip = false;\n\n /** @ignore */\n private _lastActiveElement: HTMLElement;\n\n /** @ignore */\n private _targetEvents: {\n mouseenter?: Subscription;\n mouseleave?: Subscription;\n click?: Subscription;\n } = {};\n\n /** @ignore */\n private _overlayEvents: {\n attach?: Subscription;\n detach?: Subscription;\n scroll?: Subscription;\n outside?: Subscription;\n } = {};\n\n //\n\n /** @ignore */\n private _offsetX = 0;\n\n /**\n * Gets or sets the horizontal offset and updates it accordingly.\n */\n @Input()\n\n /**\n * Gets the horizontal offset value.\n */\n public get offsetX(): number {\n return this._offsetX;\n }\n\n /**\n * Sets the horizontal offset and updates it with a callback.\n */\n public set offsetX(v: number) {\n this.setOption({\n name: 'offsetX',\n value: v,\n afterCallback: () => {\n this.updateOffset();\n },\n });\n }\n //\n\n /** @ignore */\n private _offsetY = 0;\n\n /**\n * Vertical offset with update callback.\n */\n @Input()\n\n /**\n * Gets the vertical offset of the component.\n */\n public get offsetY(): number {\n return this._offsetY;\n }\n\n /**\n * Sets the vertical offset and updates the component position.\n */\n public set offsetY(v: number) {\n this.setOption({\n name: 'offsetY',\n value: v,\n afterCallback: () => {\n this.updateOffset();\n },\n });\n }\n\n //\n\n /** @ignore */\n private _target!: HTMLElement;\n\n /**\n * Gets or sets the target element, supporting HTMLElement, ElementRef, or MXBaseComponent.\n */\n @Input()\n\n /**\n * Gets the current target element.\n */\n public get target(): HTMLElement | ElementRef | MXBaseComponent {\n return this._target;\n }\n\n /**\n * Sets the target element and updates event bindings.\n */\n public set target(v: HTMLElement | ElementRef | MXBaseComponent) {\n this.removeTargetEvents();\n if (v instanceof HTMLElement) this._target = v;\n else if (v instanceof ElementRef) this._target = v.nativeElement;\n else if (typeof v?.getHostElement == 'function') this._target = v.getHostElement();\n //\n this.bindTargetEvents();\n }\n //\n\n /** @ignore */\n private _defautPlacements: AXConnectedPosition[] = convertToPlacement('bottom-start');\n\n /** @ignore */\n private _placements: AXConnectedPosition[] = [...this._defautPlacements];\n\n /** @ignore */\n private _placement: AXPlacementType = this._placements;\n\n /**\n * Gets or sets the component's placement and updates position settings.\n */\n @Input()\n\n /**\n * Gets the current placement of the component.\n */\n public get placement(): AXPlacementType {\n return this._placement;\n }\n\n /**\n * Sets the component's placement and updates its position settings.\n */\n public set placement(v: AXPlacementType) {\n this.setOption({\n name: 'placement',\n value: v,\n afterCallback: (o, n) => {\n const converted = convertToPlacement(n);\n this._placements = converted.length ? converted : this._defautPlacements;\n this.updateOffset();\n this.updatePositionStrategy();\n },\n });\n }\n //\n\n /** @ignore */\n private _portal: Portal<unknown>;\n\n /** @ignore */\n private _componentRef: ComponentRef<unknown>;\n\n /**\n * Gets the reference to the component.\n */\n public get componentRef(): ComponentRef<unknown> {\n return this._componentRef;\n }\n\n /**\n * Holds the context data for the component.\n */\n public context: unknown;\n\n //\n\n /** @ignore */\n @ViewChild('baseTemplate', { static: true })\n _baseTemplate: TemplateRef<unknown>;\n //\n\n /**\n * Defines the content to be displayed, which can be a template or a component.\n */\n @Input()\n content: TemplateRef<unknown> | ComponentType<unknown>;\n //\n\n /** @ignore */\n private _openOn: AXPopoverOpenTrigger = 'toggle';\n\n /**\n * Gets or sets the trigger for opening the popover and updates target events.\n */\n @Input()\n\n /**\n * Gets the trigger for opening the popover.\n */\n public get openOn(): AXPopoverOpenTrigger {\n return this._openOn;\n }\n\n /**\n * Sets the trigger for opening the popover and updates target events.\n */\n public set openOn(v: AXPopoverOpenTrigger) {\n this.setOption({\n name: 'openOn',\n value: v,\n afterCallback: () => {\n this.bindTargetEvents();\n },\n });\n }\n //\n\n /** @ignore */\n private _closeOn: AXPopoverCloseTrigger = 'clickOut';\n\n /**\n * Gets or sets the trigger for closing the popover.\n */\n @Input()\n public get closeOn(): AXPopoverCloseTrigger {\n return this._closeOn;\n }\n\n /**\n * Sets the trigger for closing the popover and rebinds target events.\n * @param v\n */\n public set closeOn(v: AXPopoverCloseTrigger) {\n this.setOption({\n name: 'closeOn',\n value: v,\n afterCallback: () => {\n this.bindTargetEvents();\n },\n });\n }\n\n //\n\n /**\n * Determines if a backdrop should be displayed behind the popover.\n */\n @Input()\n hasBackdrop = false;\n //\n\n /**\n * Delay in milliseconds before the popover opens after a trigger event.\n */\n @Input()\n openAfter = 200;\n\n /**\n * Delay in milliseconds before the popover closes after a trigger event.\n */\n @Input()\n closeAfter = 200;\n\n /**\n * CSS class to apply to the backdrop element.\n */\n @Input()\n backdropClass: string;\n\n /**\n * Enables or disables adaptivity.\n */\n @Input()\n adaptivityEnabled = false;\n //\n\n /**\n * Emits when the component is opened.\n * @event\n */\n @Output()\n onOpened: EventEmitter<AXEvent> = new EventEmitter<AXEvent>();\n\n /**\n * Emits when the component is closed.\n * @event\n */\n @Output()\n onClosed: EventEmitter<AXEvent> = new EventEmitter<AXEvent>();\n\n /** @ignore */\n private _emitOnOpenedEvent() {\n this.onOpened.emit({\n component: this,\n htmlElement: this.getHostElement(),\n });\n }\n\n /** @ignore */\n private _emitOnClosedEvent() {\n this.onClosed.emit({\n component: this,\n htmlElement: this.getHostElement(),\n });\n }\n //\n\n /** @ignore */\n protected _handleMouseEnter(e: MouseEvent) {\n this._isMouseOverTooltip = true;\n }\n\n /** @ignore */\n protected _handleMouseLeave(e: MouseEvent) {\n this._isMouseOverTooltip = false;\n setTimeout(() => {\n if (!this._isMouseOverButton && this.closeOn == 'leave') {\n this.close();\n }\n }, 250);\n }\n\n /** @ignore */\n private removeTargetEvents(): void {\n Object.entries(this._targetEvents).forEach((e) => {\n e[1].unsubscribe();\n });\n }\n\n /** @ignore */\n private bindTargetEvents() {\n this.removeTargetEvents();\n if (!this._target) return;\n const targetMouseEnter$ = fromEvent(this._target, 'mouseenter');\n const targetMouseLeave$ = fromEvent(this._target, 'mouseleave');\n\n if (this.openOn == 'hover') {\n this._targetEvents.mouseenter = targetMouseEnter$.pipe(delay(this.openAfter)).subscribe(() => {\n this._isMouseOverButton = true;\n this.open();\n });\n }\n\n if (this.closeOn == 'leave') {\n this._targetEvents.mouseleave = targetMouseLeave$.pipe(delay(this.closeAfter)).subscribe(() => {\n this._isMouseOverButton = false;\n if (!this._isMouseOverTooltip) {\n this.close();\n }\n });\n }\n\n if (this.openOn === 'click' || this.openOn === 'toggle') {\n const click$ = fromEvent<MouseEvent>(this._target, 'click');\n this._targetEvents.click = click$.subscribe((e) => {\n this.openOn == 'toggle' ? this.toggle() : this.open();\n });\n }\n }\n //\n\n /** @ignore */\n private bindOverlayEvents() {\n this.removeOverlayEvents();\n this._overlayEvents.attach = this._overlayRef.attachments().subscribe(() => {\n if (this.openOn == 'hover') {\n this._overlayRef.overlayElement.addEventListener('mouseenter', this._handleMouseEnter.bind(this));\n }\n if (this.closeOn == 'leave') {\n this._overlayRef.overlayElement.addEventListener('mouseleave', this._handleMouseLeave.bind(this));\n }\n //\n this._overlayEvents.outside = this._overlayRef._outsidePointerEvents.subscribe((e: MouseEvent) => {\n const el = e.target as HTMLElement;\n if (\n this.closeOn == 'clickOut' &&\n this.isOpen &&\n !this._target.contains(el) &&\n !this._overlayRef?.overlayElement?.contains(el)\n ) {\n this.close();\n }\n });\n //\n\n this._overlayEvents.scroll = this._platform.scroll.subscribe((c) => {\n //__axContext__\n const el = c.nativeEvent.target as HTMLElement;\n if (!this.isActionsheetStyle) {\n if (el == (document as any)) {\n this.close();\n return;\n }\n if (\n el?.closest &&\n !el.closest('.ax-overlay-pane') &&\n !this._target.contains(el) &&\n !this._overlayRef?.overlayElement?.contains(el)\n ) {\n this.close();\n }\n }\n });\n });\n }\n\n /** @ignore */\n private removeOverlayEvents() {\n this._overlayRef?.overlayElement.removeEventListener('mouseenter', this._handleMouseEnter.bind(this));\n this._overlayRef?.overlayElement.addEventListener('mouseleave', this._handleMouseLeave.bind(this));\n Object.entries(this._overlayEvents).forEach((e) => {\n e[1].unsubscribe();\n });\n }\n\n //\n /**\n * Toggles the component's open state.\n */\n toggle() {\n this.isOpen ? this.close() : this.open();\n }\n\n //\n /**\n * Closes the component if it's open, detaches the overlay, restores focus, and emits the closed event.\n */\n close() {\n if (!this.isOpen) {\n return;\n }\n this._overlayRef?.detach();\n this.restoreFocus();\n this._emitOnClosedEvent();\n }\n\n //\n /**\n * Opens the component if it's not already open, saves focus, opens the overlay, and emits the opened event.\n */\n open() {\n if (this.isOpen) {\n return;\n }\n this.saveFocus();\n this.openOverlayInternal();\n this._emitOnOpenedEvent();\n }\n\n /** @ignore */\n private saveFocus() {\n if (isBrowser()) {\n this._lastActiveElement = document.activeElement as HTMLElement;\n }\n }\n\n /** @ignore */\n private restoreFocus() {\n if (this._lastActiveElement?.focus) {\n this._lastActiveElement.focus();\n }\n }\n\n /** @ignore */\n private openOverlayInternal() {\n const targetRef = this._target;\n if (!targetRef) return;\n\n //if (!this._overlayRef) {\n if (this.isActionsheetStyle) {\n this._overlayRef = this._overlay.create({\n positionStrategy: this._overlay.position().global().bottom().centerHorizontally(),\n disposeOnNavigation: true,\n scrollStrategy: this._overlay.scrollStrategies.block(),\n panelClass: ['ax-actionsheet-base', 'ax-animate-slideInUp', 'ax-animate-faster'],\n hasBackdrop: true,\n width: '100%',\n });\n } else {\n this._overlayRef = this._overlay.create({\n positionStrategy: this._overlay\n .position()\n .flexibleConnectedTo(targetRef)\n .withPositions(this._placements)\n .withPush(false),\n scrollStrategy: this._overlay.scrollStrategies.noop(),\n disposeOnNavigation: true,\n panelClass: ['ax-animate-fadeIn', 'ax-animate-faster'],\n maxHeight: 'unset',\n hasBackdrop: this.hasBackdrop,\n backdropClass: [this.backdropClass || 'cdk-overlay-transparent-backdrop'],\n direction: AXHtmlUtil.isRtl(this.getHostElement()) ? 'rtl' : 'ltr',\n });\n // this._overlayRef.setDirection()\n }\n\n //\n this.bindOverlayEvents();\n //}\n //\n if (this.content instanceof TemplateRef) {\n this._portal = new TemplatePortal(this.content, this.getViewContainer(), {\n $implicit: this.context,\n ref: this,\n });\n this._overlayRef?.attach(this._portal);\n } else if (typeof this.content === 'function') {\n this._portal = new ComponentPortal(this.content);\n this._componentRef = this._overlayRef?.attach(this._portal);\n Object.assign(this._componentRef.instance, this.context);\n } else {\n this._portal = new TemplatePortal(this._baseTemplate, this.getViewContainer(), {\n $implicit: this.context,\n ref: this,\n });\n this._overlayRef?.attach(this._portal);\n }\n }\n\n /**\n * Checks if the overlay is currently open.\n * @returns {boolean}\n */\n get isOpen(): boolean {\n return this._overlayRef ? this._overlayRef.hasAttached() : false;\n }\n\n /**\n * Determines if the actionsheet style should be applied.\n * @returns {boolean}\n */\n get isActionsheetStyle(): boolean {\n return this._platform.is('SM') && this.adaptivityEnabled;\n }\n\n /** @ignore */\n private updatePositionStrategy(): void {\n const targetRef = this._target;\n if (!targetRef) return;\n let strategy: PositionStrategy;\n if (this.isActionsheetStyle) {\n strategy = this._overlay.position().global().bottom().centerHorizontally();\n } else {\n strategy = this._overlay\n .position()\n .flexibleConnectedTo(targetRef)\n .withPositions(this._placements)\n .withPush(false);\n }\n this._overlayRef?.updatePositionStrategy(strategy);\n }\n\n /** @ignore */\n private updateOffset() {\n this._placements?.forEach((p) => {\n if (this.offsetY != null) p.offsetY = this.offsetY;\n if (this.offsetX != null) p.offsetX = this.offsetX;\n });\n }\n\n /**\n * Updates the position of the overlay and focuses on it.\n */\n public updatePosition(): void {\n this._overlayRef?.updatePosition();\n this.focus();\n }\n\n /**\n * Focuses the overlay element.\n */\n public focus(): void {\n //TODO: need this??\n }\n //\n\n protected override ngOnInit(): void {\n super.ngOnInit();\n // this.platformService.directionChange.subscribe((c) => {\n // this.isRtl = c.data == 'rtl';\n // });\n }\n\n /** @ignore */\n ngOnDestroy(): void {\n this.removeTargetEvents();\n this.removeOverlayEvents();\n this._overlayRef?.detach();\n this._overlayRef?.dispose();\n }\n}\n","<ng-template #baseTemplate>\n <ng-content></ng-content>\n</ng-template>","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { AXPopoverComponent } from './popover.component';\n\n@NgModule({\n declarations: [AXPopoverComponent],\n imports: [CommonModule],\n exports: [AXPopoverComponent],\n providers: [],\n})\nexport class AXPopoverModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;AA+BA;;;AAGG;AAQG,MAAO,kBAAmB,SAAQ,eAAe,CAAA;AAPvD,IAAA,WAAA,GAAA;;AAQU,QAAA,IAAA,CAAA,eAAe,GAAG,MAAM,CAAC,UAAU,CAAC;;AAGpC,QAAA,IAAA,CAAA,SAAS,GAAe,MAAM,CAAC,UAAU,CAAC;;AAG1C,QAAA,IAAA,CAAA,QAAQ,GAAY,MAAM,CAAC,OAAO,CAAC;;QAMnC,IAAkB,CAAA,kBAAA,GAAG,KAAK;;QAG1B,IAAmB,CAAA,mBAAA,GAAG,KAAK;;QAM3B,IAAa,CAAA,aAAA,GAIjB,EAAE;;QAGE,IAAc,CAAA,cAAA,GAKlB,EAAE;;;QAKE,IAAQ,CAAA,QAAA,GAAG,CAAC;;;QA6BZ,IAAQ,CAAA,QAAA,GAAG,CAAC;;;AA0DZ,QAAA,IAAA,CAAA,iBAAiB,GAA0B,kBAAkB,CAAC,cAAc,CAAC;;AAG7E,QAAA,IAAA,CAAA,WAAW,GAA0B,CAAC,GAAG,IAAI,CAAC,iBAAiB,CAAC;;AAGhE,QAAA,IAAA,CAAA,UAAU,GAAoB,IAAI,CAAC,WAAW;;;QAgE9C,IAAO,CAAA,OAAA,GAAyB,QAAQ;;;QA6BxC,IAAQ,CAAA,QAAA,GAA0B,UAAU;;AA0BpD;;AAEG;QAEH,I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AA,CAAA,CAAA;;2FAIX,eAAe,EAAA,UAAA,EAAA,CAAA;kBAN3B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,YAAY,EAAE,CAAC,kBAAkB,CAAC;oBAClC,OAAO,EAAE,CAAC,YAAY,CAAC;oBACvB,OAAO,EAAE,CAAC,kBAAkB,CAAC;AAC7B,oBAAA,SAAS,EAAE,EAAE;AACd,iBAAA;;;ACTD;;AAEG;;;;"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"acorex-components-popup.mjs","sources":["../../../../libs/components/popup/src/lib/popup.component.ts","../../../../libs/components/popup/src/lib/popup.component.html","../../../../libs/components/popup/src/lib/popup.service.ts","../../../../libs/components/popup/src/lib/popup.module.ts","../../../../libs/components/popup/src/acorex-components-popup.ts"],"sourcesContent":["import { AXPlatform } from '@acorex/core/platform';\nimport { CdkPortalOutletAttachedRef, ComponentPortal, Portal, TemplatePortal } from '@angular/cdk/portal';\nimport {\n ChangeDetectionStrategy,\n Component,\n ComponentRef,\n HostListener,\n Inject,\n NgZone,\n OnInit,\n TemplateRef,\n ViewContainerRef,\n ViewEncapsulation,\n} from '@angular/core';\n\nimport { AXClosbaleComponent, AXComponentCloseEvent, AXComponentClosing, MXBaseComponent } from '@acorex/components/common';\nimport { AXLoadingService } from '@acorex/components/loading';\nimport { DIALOG_DATA, DialogRef } from '@angular/cdk/dialog';\nimport { AXPopupData } from './popup.interface';\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-popup',\n templateUrl: './popup.component.html',\n styleUrls: ['./popup.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n providers: [{ provide: AXClosbaleComponent, useExisting: AXPopupComponent }],\n})\nexport class AXPopupComponent extends MXBaseComponent implements OnInit {\n\n /**\n * Indicates whether the component is loading.\n * @defaultValue true\n */\n isLoading = true;\n\n /** @ignore */\n private _loadingId: number;\n\n /** @ignore */\n protected _selectedPortal: Portal<unknown>;\n\n /** @ignore */\n protected _footerPortal: Portal<unknown>;\n\n /** @ignore */\n protected _headerPortal: Portal<unknown>;\n\n /** @ignore */\n private _componentRef: any;\n\n/** @ignore */\n constructor(\n\n /** @ignore */\n private _zone: NgZone,\n\n /** @ignore */\n private _viewContainerRef: ViewContainerRef,\n\n /** @ignore */\n private loadingService: AXLoadingService,\n\n /** @ignore */\n private _platform: AXPlatform,\n @Inject(DIALOG_DATA)\n\n /** @ignore */\n protected data: AXPopupData,\n\n /** @ignore */\n private dialogRef: DialogRef<AXComponentCloseEvent>,\n ) {\n\n /** @ignore */\n super();\n }\n\n /** @ignore */\n override ngOnInit() {\n super.ngOnInit();\n if (this._platform.is('SM')) {\n this.data.draggable = false;\n }\n this._loadingId = this.loadingService.show({\n location: this.getHostElement(),\n });\n //\n if (this.data.content instanceof TemplateRef) {\n this._selectedPortal = new TemplatePortal(this.data.content, this._viewContainerRef, {\n $implicit: this.data,\n ref: this,\n });\n this.cdr.markForCheck();\n } else if (typeof this.data.content === 'function') {\n this._selectedPortal = new ComponentPortal(this.data.content);\n this.cdr.markForCheck();\n }\n }\n\n /** @ignore */\n _handleAttched(ref: CdkPortalOutletAttachedRef) {\n ref = ref as ComponentRef<unknown>;\n if (ref.instance) {\n this._componentRef = ref.instance;\n Object.assign(this._componentRef, this.data.data);\n Object.assign(this._componentRef, { _isPopup: true });\n Object.assign(this._componentRef, {\n setTitle: (title: string) => {\n this.data.title = title;\n },\n });\n if (ref.instance.onClosed) {\n ref.instance.onClosed.subscribe((e: AXComponentCloseEvent) => {\n this.close(e.data);\n });\n }\n }\n this._zone.runOutsideAngular(() => {\n setTimeout(() => {\n const main = this.getHostElement().querySelector<HTMLDivElement>('.ax-popup-main-container');\n const popHeader = this.getHostElement().querySelector<HTMLDivElement>('.ax-popup-header-container');\n const popFooter = this.getHostElement().querySelector<HTMLDivElement>('.ax-popup-footer-container');\n const footer = main.querySelector<HTMLDivElement>('ax-footer');\n const header = main.querySelector<HTMLDivElement>('ax-header');\n if (footer) {\n popFooter?.append(footer);\n }\n if (header) {\n popHeader.innerHTML = '';\n popHeader.append(header);\n }\n this.focus();\n });\n });\n this.loadingService.hide(this._loadingId);\n this.cdr.markForCheck();\n }\n\n /** @ignore */\n @HostListener('keydown.escape', ['$event'])\n onKeydownHandler(event: KeyboardEvent) {\n const focusedOrHasFocused = this.getHostElement().matches(':focus-within');\n if (this.data.closeButton && focusedOrHasFocused) {\n this.close();\n }\n }\n\n /** @ignore */\n _handleCloseClick() {\n this.close();\n }\n\n /** @ignore */\n ngOnDestroy() {\n this.loadingService.hide(this._loadingId);\n }\n\n /**\n * Sets focus on the `.ax-popup` element within the host element after a short delay.\n */\n focus() {\n setTimeout(() => this.getHostElement().querySelector<HTMLDivElement>('.ax-popup')?.focus());\n }\n\n /**\n * Closes the dialog, emitting component reference, host element, and optional data.\n * @param {unknown} [data]\n */\n close(data?: unknown) {\n const closeFn = () => {\n this.dialogRef.close({\n component: this._componentRef,\n htmlElement: this.getHostElement(),\n data: data,\n });\n };\n if (typeof this._componentRef.onClosing === 'function') {\n const ee: AXComponentClosing = {\n cancel: false,\n data,\n };\n const closingResult = this._componentRef.onClosing(ee);\n if (closingResult instanceof Promise) {\n closingResult.then(() => {\n if (!ee.cancel) {\n closeFn();\n }\n });\n } else {\n if (!ee.cancel) {\n closeFn();\n }\n }\n } else {\n closeFn();\n }\n }\n}\n","<div class=\"ax-popup-wrapper \" aria-modal=\"true\" [cdkTrapFocus]=\"true\">\n <div class=\"ax-popup ax-popup-{{ data.size }}\" tabindex=\"0\" cdkDrag [cdkDragDisabled]=\"!data.draggable\">\n <div cdkDragHandle class=\"ax-popup-header-container\">\n @if(data.header){\n <div class=\"ax-popup-header\">\n <span class=\"ax-popup-title\">{{ data.title | translate | async }}</span>\n @if(data.closeButton){\n <ax-close-button tabindex=\"1\"></ax-close-button>\n }\n </div>\n }\n </div>\n <div class=\"ax-popup-main-container ax-loading-container\">\n <div class=\"ax-popup-body-container\">\n <ng-template [cdkPortalOutlet]=\"_selectedPortal\" (attached)=\"_handleAttched($event)\"></ng-template>\n </div>\n <div class=\"ax-popup-footer-container\"></div>\n </div>\n </div>\n</div>","import { AXComponentCloseEvent, AXComponentClosedPromise } from '@acorex/components/common';\nimport { Dialog } from '@angular/cdk/dialog';\nimport { Injectable, inject } from '@angular/core';\nimport { AXPopupComponent } from './popup.component';\nimport { AXPopupConfig, AXPopupContentType } from './popup.interface';\n\n/**\n * This is a service which you can create popup with it\n *\n * @category Components\n */\n@Injectable()\nexport class AXPopupService {\n private dialog: Dialog = inject(Dialog);\n\n /**\n * Open popup 1\n */\n open(content: AXPopupContentType, title: string): AXComponentClosedPromise;\n /**\n * Open popup 2\n */\n open(content: AXPopupContentType, config?: AXPopupConfig): AXComponentClosedPromise;\n\n /**\n * @ignore\n */\n open(arg1, arg2): AXComponentClosedPromise {\n let config: AXPopupConfig = {\n closeButton: true,\n header: true,\n size: 'md',\n maximizable: false,\n draggable: true,\n hasBackdrop: true,\n closeOnBackdropClick: false,\n data: {},\n };\n if (typeof arg2 === 'string') {\n config.title = arg2;\n } else {\n config = Object.assign(config, arg2);\n }\n\n const dialogRef = this.dialog.open<AXComponentCloseEvent, AXPopupConfig, AXPopupComponent>(AXPopupComponent, {\n data: Object.assign(config, { content: arg1 }),\n autoFocus: true,\n restoreFocus: true,\n closeOnNavigation: true,\n closeOnDestroy: true,\n hasBackdrop: config.hasBackdrop,\n backdropClass: config.backdropClass,\n disableClose: config.closeOnBackdropClick ? false : true,\n viewContainerRef: config.viewContainerRef,\n providers: config.providers,\n });\n const promise = new AXComponentClosedPromise((resolve) => {\n dialogRef.closed.subscribe((d) => {\n if (resolve) {\n resolve({\n sender: d.component,\n data: d.data,\n });\n }\n });\n });\n return promise;\n }\n}\n","import { AXCommonModule } from '@acorex/components/common';\nimport { AXDecoratorModule } from '@acorex/components/decorators';\nimport { AXTranslationModule } from '@acorex/core/translation';\nimport { A11yModule } from '@angular/cdk/a11y';\nimport { DialogModule } from '@angular/cdk/dialog';\nimport { DragDropModule } from '@angular/cdk/drag-drop';\nimport { PortalModule } from '@angular/cdk/portal';\nimport { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { AXPopupComponent } from './popup.component';\nimport { AXPopupService } from './popup.service';\n\nconst COMPONENT = [AXPopupComponent];\nconst MODULES = [\n CommonModule,\n AXCommonModule,\n DragDropModule,\n A11yModule,\n PortalModule,\n AXDecoratorModule,\n DialogModule,\n AXTranslationModule,\n];\n\n@NgModule({\n declarations: [...COMPONENT],\n imports: [...MODULES],\n exports: [...COMPONENT],\n providers: [AXPopupService],\n})\nexport class AXPopupModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAoBA;;;;AAIG;AASG,MAAO,gBAAiB,SAAQ,eAAe,CAAA;;AAwBnD,IAAA,WAAA;;IAGU,KAAa;;IAGb,iBAAmC;;IAGnC,cAAgC;;AAGhC,IAAA,SAAqB,EAInB,IAAiB;;IAGnB,SAA2C,EAAA;;AAInD,QAAA,KAAK,EAAE,CAAC;QApBA,IAAK,CAAA,KAAA,GAAL,KAAK,CAAQ;QAGb,IAAiB,CAAA,iBAAA,GAAjB,iBAAiB,CAAkB;QAGnC,IAAc,CAAA,cAAA,GAAd,cAAc,CAAkB;QAGhC,IAAS,CAAA,SAAA,GAAT,SAAS,CAAY;QAInB,IAAI,CAAA,IAAA,GAAJ,IAAI,CAAa;QAGnB,IAAS,CAAA,SAAA,GAAT,SAAS,CAAkC;AAzCrD;;;AAGC;QACD,IAAS,CAAA,SAAA,GAAG,IAAI,CAAC;KA0ChB;;IAGQ,QAAQ,GAAA;QACf,KAAK,CAAC,QAAQ,EAAE,CAAC;QACjB,IAAI,IAAI,CAAC,SAAS,CAAC,EAAE,CAAC,IAAI,CAAC,EAAE;AAC3B,YAAA,IAAI,CAAC,IAAI,CAAC,SAAS,GAAG,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YACd,UAAU;YACV,YAAY;YACZ,iBAAiB;YACjB,YAAY;AACZ,YAAA,mBAAmB,aATF,gBAAgB,CAAA,EAAA,CAAA,CAAA,EAAA;AAkBtB,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,EAAA;;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,CAAA;;;AC7BD;;AAEG;;;;"}
|
1
|
+
{"version":3,"file":"acorex-components-popup.mjs","sources":["../../../../libs/components/popup/src/lib/popup.component.ts","../../../../libs/components/popup/src/lib/popup.component.html","../../../../libs/components/popup/src/lib/popup.service.ts","../../../../libs/components/popup/src/lib/popup.module.ts","../../../../libs/components/popup/src/acorex-components-popup.ts"],"sourcesContent":["import { AXPlatform } from '@acorex/core/platform';\nimport { CdkPortalOutletAttachedRef, ComponentPortal, Portal, TemplatePortal } from '@angular/cdk/portal';\nimport {\n ChangeDetectionStrategy,\n Component,\n ComponentRef,\n HostListener,\n Inject,\n NgZone,\n OnInit,\n TemplateRef,\n ViewContainerRef,\n ViewEncapsulation,\n} from '@angular/core';\n\nimport { AXClosbaleComponent, AXComponentCloseEvent, AXComponentClosing, MXBaseComponent } from '@acorex/components/common';\nimport { AXLoadingService } from '@acorex/components/loading';\nimport { DIALOG_DATA, DialogRef } from '@angular/cdk/dialog';\nimport { AXPopupData } from './popup.interface';\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-popup',\n templateUrl: './popup.component.html',\n styleUrls: ['./popup.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n providers: [{ provide: AXClosbaleComponent, useExisting: AXPopupComponent }],\n})\nexport class AXPopupComponent extends MXBaseComponent implements OnInit {\n\n /**\n * Indicates whether the component is loading.\n * @defaultValue true\n */\n isLoading = true;\n\n /** @ignore */\n private _loadingId: number;\n\n /** @ignore */\n protected _selectedPortal: Portal<unknown>;\n\n /** @ignore */\n protected _footerPortal: Portal<unknown>;\n\n /** @ignore */\n protected _headerPortal: Portal<unknown>;\n\n /** @ignore */\n private _componentRef: any;\n\n/** @ignore */\n constructor(\n\n /** @ignore */\n private _zone: NgZone,\n\n /** @ignore */\n private _viewContainerRef: ViewContainerRef,\n\n /** @ignore */\n private loadingService: AXLoadingService,\n\n /** @ignore */\n private _platform: AXPlatform,\n @Inject(DIALOG_DATA)\n\n /** @ignore */\n protected data: AXPopupData,\n\n /** @ignore */\n private dialogRef: DialogRef<AXComponentCloseEvent>,\n ) {\n\n /** @ignore */\n super();\n }\n\n /** @ignore */\n override ngOnInit() {\n super.ngOnInit();\n if (this._platform.is('SM')) {\n this.data.draggable = false;\n }\n this._loadingId = this.loadingService.show({\n location: this.getHostElement(),\n });\n //\n if (this.data.content instanceof TemplateRef) {\n this._selectedPortal = new TemplatePortal(this.data.content, this._viewContainerRef, {\n $implicit: this.data,\n ref: this,\n });\n this.cdr.markForCheck();\n } else if (typeof this.data.content === 'function') {\n this._selectedPortal = new ComponentPortal(this.data.content);\n this.cdr.markForCheck();\n }\n }\n\n /** @ignore */\n _handleAttched(ref: CdkPortalOutletAttachedRef) {\n ref = ref as ComponentRef<unknown>;\n if (ref.instance) {\n this._componentRef = ref.instance;\n Object.assign(this._componentRef, this.data.data);\n Object.assign(this._componentRef, { _isPopup: true });\n Object.assign(this._componentRef, {\n setTitle: (title: string) => {\n this.data.title = title;\n },\n });\n if (ref.instance.onClosed) {\n ref.instance.onClosed.subscribe((e: AXComponentCloseEvent) => {\n this.close(e.data);\n });\n }\n }\n this._zone.runOutsideAngular(() => {\n setTimeout(() => {\n const main = this.getHostElement().querySelector<HTMLDivElement>('.ax-popup-main-container');\n const popHeader = this.getHostElement().querySelector<HTMLDivElement>('.ax-popup-header-container');\n const popFooter = this.getHostElement().querySelector<HTMLDivElement>('.ax-popup-footer-container');\n const footer = main.querySelector<HTMLDivElement>('ax-footer');\n const header = main.querySelector<HTMLDivElement>('ax-header');\n if (footer) {\n popFooter?.append(footer);\n }\n if (header) {\n popHeader.innerHTML = '';\n popHeader.append(header);\n }\n this.focus();\n });\n });\n this.loadingService.hide(this._loadingId);\n this.cdr.markForCheck();\n }\n\n /** @ignore */\n @HostListener('keydown.escape', ['$event'])\n onKeydownHandler(event: KeyboardEvent) {\n const focusedOrHasFocused = this.getHostElement().matches(':focus-within');\n if (this.data.closeButton && focusedOrHasFocused) {\n this.close();\n }\n }\n\n /** @ignore */\n _handleCloseClick() {\n this.close();\n }\n\n /** @ignore */\n ngOnDestroy() {\n this.loadingService.hide(this._loadingId);\n }\n\n /**\n * Sets focus on the `.ax-popup` element within the host element after a short delay.\n */\n focus() {\n setTimeout(() => this.getHostElement().querySelector<HTMLDivElement>('.ax-popup')?.focus());\n }\n\n /**\n * Closes the dialog, emitting component reference, host element, and optional data.\n * @param {unknown} [data]\n */\n close(data?: unknown) {\n const closeFn = () => {\n this.dialogRef.close({\n component: this._componentRef,\n htmlElement: this.getHostElement(),\n data: data,\n });\n };\n if (typeof this._componentRef.onClosing === 'function') {\n const ee: AXComponentClosing = {\n cancel: false,\n data,\n };\n const closingResult = this._componentRef.onClosing(ee);\n if (closingResult instanceof Promise) {\n closingResult.then(() => {\n if (!ee.cancel) {\n closeFn();\n }\n });\n } else {\n if (!ee.cancel) {\n closeFn();\n }\n }\n } else {\n closeFn();\n }\n }\n}\n","<div class=\"ax-popup-wrapper \" aria-modal=\"true\" [cdkTrapFocus]=\"true\">\n <div class=\"ax-popup ax-popup-{{ data.size }}\" tabindex=\"0\" cdkDrag [cdkDragDisabled]=\"!data.draggable\">\n <div cdkDragHandle class=\"ax-popup-header-container\">\n @if(data.header){\n <div class=\"ax-popup-header\">\n <span class=\"ax-popup-title\">{{ data.title | translate | async }}</span>\n @if(data.closeButton){\n <ax-close-button tabindex=\"1\"></ax-close-button>\n }\n </div>\n }\n </div>\n <div class=\"ax-popup-main-container ax-loading-container\">\n <div class=\"ax-popup-body-container\">\n <ng-template [cdkPortalOutlet]=\"_selectedPortal\" (attached)=\"_handleAttched($event)\"></ng-template>\n </div>\n <div class=\"ax-popup-footer-container\"></div>\n </div>\n </div>\n</div>","import { AXComponentCloseEvent, AXComponentClosedPromise } from '@acorex/components/common';\nimport { Dialog } from '@angular/cdk/dialog';\nimport { Injectable, inject } from '@angular/core';\nimport { AXPopupComponent } from './popup.component';\nimport { AXPopupConfig, AXPopupContentType } from './popup.interface';\n\n/**\n * This is a service which you can create popup with it\n *\n * @category Components\n */\n@Injectable()\nexport class AXPopupService {\n private dialog: Dialog = inject(Dialog);\n\n /**\n * Open popup 1\n */\n open(content: AXPopupContentType, title: string): AXComponentClosedPromise;\n /**\n * Open popup 2\n */\n open(content: AXPopupContentType, config?: AXPopupConfig): AXComponentClosedPromise;\n\n /**\n * @ignore\n */\n open(arg1, arg2): AXComponentClosedPromise {\n let config: AXPopupConfig = {\n closeButton: true,\n header: true,\n size: 'md',\n maximizable: false,\n draggable: true,\n hasBackdrop: true,\n closeOnBackdropClick: false,\n data: {},\n };\n if (typeof arg2 === 'string') {\n config.title = arg2;\n } else {\n config = Object.assign(config, arg2);\n }\n\n const dialogRef = this.dialog.open<AXComponentCloseEvent, AXPopupConfig, AXPopupComponent>(AXPopupComponent, {\n data: Object.assign(config, { content: arg1 }),\n autoFocus: true,\n restoreFocus: true,\n closeOnNavigation: true,\n closeOnDestroy: true,\n hasBackdrop: config.hasBackdrop,\n backdropClass: config.backdropClass,\n disableClose: config.closeOnBackdropClick ? false : true,\n viewContainerRef: config.viewContainerRef,\n providers: config.providers,\n });\n const promise = new AXComponentClosedPromise((resolve) => {\n dialogRef.closed.subscribe((d) => {\n if (resolve) {\n resolve({\n sender: d.component,\n data: d.data,\n });\n }\n });\n });\n return promise;\n }\n}\n","import { AXCommonModule } from '@acorex/components/common';\nimport { AXDecoratorModule } from '@acorex/components/decorators';\nimport { AXTranslationModule } from '@acorex/core/translation';\nimport { A11yModule } from '@angular/cdk/a11y';\nimport { DialogModule } from '@angular/cdk/dialog';\nimport { DragDropModule } from '@angular/cdk/drag-drop';\nimport { PortalModule } from '@angular/cdk/portal';\nimport { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { AXPopupComponent } from './popup.component';\nimport { AXPopupService } from './popup.service';\n\nconst COMPONENT = [AXPopupComponent];\nconst MODULES = [\n CommonModule,\n AXCommonModule,\n DragDropModule,\n A11yModule,\n PortalModule,\n AXDecoratorModule,\n DialogModule,\n AXTranslationModule,\n];\n\n@NgModule({\n declarations: [...COMPONENT],\n imports: [...MODULES],\n exports: [...COMPONENT],\n providers: [AXPopupService],\n})\nexport class AXPopupModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAoBA;;;;AAIG;AASG,MAAO,gBAAiB,SAAQ,eAAe,CAAA;;AAwBnD,IAAA,WAAA;;IAGU,KAAa;;IAGb,iBAAmC;;IAGnC,cAAgC;;AAGhC,IAAA,SAAqB,EAInB,IAAiB;;IAGnB,SAA2C,EAAA;;AAInD,QAAA,KAAK,EAAE;QApBC,IAAK,CAAA,KAAA,GAAL,KAAK;QAGL,IAAiB,CAAA,iBAAA,GAAjB,iBAAiB;QAGjB,IAAc,CAAA,cAAA,GAAd,cAAc;QAGd,IAAS,CAAA,SAAA,GAAT,S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AA,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;;;AC7BD;;AAEG;;;;"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"acorex-components-progress-bar.mjs","sources":["../../../../libs/components/progress-bar/src/lib/progress-bar.component.ts","../../../../libs/components/progress-bar/src/lib/progress-bar.component.html","../../../../libs/components/progress-bar/src/lib/progress-bar.module.ts","../../../../libs/components/progress-bar/src/acorex-components-progress-bar.ts"],"sourcesContent":["import { MXColorComponent } from '@acorex/components/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n EventEmitter,\n HostBinding,\n Input,\n Output,\n ViewChild,\n ViewEncapsulation,\n} from '@angular/core';\n\n/**\n * The Button is a component which detects user interaction and triggers a corresponding event\n *\n * @category Components\n */\n\nexport type AXProgressMode = 'determinate' | 'indeterminate' | 'buffer' | 'query';\n\n@Component({\n selector: 'ax-progress-bar',\n templateUrl: './progress-bar.component.html',\n styleUrls: ['./progress-bar.component.scss'],\n inputs: ['color'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n})\nexport class AXProgressBarComponent extends MXColorComponent {\n\n /** @ignore */\n @ViewChild('c') circle: ElementRef;\n\n /**\n * @event\n * Emits when the slider value changes.\n */\n @Output()\n ValueChange: EventEmitter<number> = new EventEmitter();\n\n /** @ignore */\n private _progress = 0;\n\n /**\n * Specifies the progress indicator mode.\n */\n @Input()\n mode: AXProgressMode = 'determinate';\n\n /**\n * Gets or sets the progress value (0-100).\n */\n @Input()\n \n /**\n * Retrieves the current progress value (0-100).\n */\n public get progress(): number {\n return this._progress;\n }\n\n /**\n * Sets the progress value (0-100).\n * @param {number} v\n */\n public set progress(v: number) {\n this.setOption({\n name: 'progress',\n value: v,\n });\n }\n\n /**\n * Emitted when the size changes.\n * @event\n */\n @Output()\n sizeChange: EventEmitter<number> = new EventEmitter();\n\n /** @ignore */\n private _height = 8;\n\n /**\n * Gets or sets the height of the component.\n * @param {number} v\n */\n @Input()\n\n /**\n * Gets the height of the component.\n */\n public get height(): number {\n return this._height;\n }\n\n /**\n * Sets the height of the component.\n * @param {number} v\n */\n public set height(v: number) {\n this.setOption({\n name: 'height',\n value: v,\n });\n }\n\n /** @ignore */\n @HostBinding('class')\n private get __hostClass(): string {\n return `ax-${this['color']}-appearance`;\n }\n}\n","<ng-content select=\"ax-prefix\"></ng-content>\n@switch (mode) {\n\n@case ('indeterminate') {\n<div class=\"ax-progress\" [style.height.px]=\"height\" role=\"progressbar\">\n <div class=\"ax-progress-bar ax-indeterminate-progress\"></div>\n</div>\n}\n@case ('query') {\n<div class=\"ax-progress\" [style.height.px]=\"height\" role=\"progressbar\">\n <div class=\"ax-progress-bar ax-query-progress\"></div>\n</div>\n}\n@case ('buffer') {\n<div class=\"ax-progress \" [style.height.px]=\"height\" role=\"progressbar\">\n <div class=\"ax-progress-bar ax-buffer-progress\"></div>\n</div>\n}\n@default {\n<div class=\"ax-progress\" [style.height.px]=\"height\" role=\"progressbar\">\n <div class=\"ax-progress-bar\" [style.width.%]=\"progress\"></div>\n</div>\n}\n\n}\n<ng-content select=\"ax-suffix\"></ng-content>\n\n<!--TODO: impliment other modes-->","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { AXProgressBarComponent } from './progress-bar.component';\n\n@NgModule({\n declarations: [AXProgressBarComponent],\n imports: [CommonModule],\n exports: [AXProgressBarComponent],\n providers: [],\n})\nexport class AXProgressBarModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;AA6BM,MAAO,sBAAuB,SAAQ,gBAAgB,CAAA;AAR5D,IAAA,WAAA,GAAA;;AAaE;;;AAGC;AAED,QAAA,IAAA,CAAA,WAAW,GAAyB,IAAI,YAAY,EAAE
|
1
|
+
{"version":3,"file":"acorex-components-progress-bar.mjs","sources":["../../../../libs/components/progress-bar/src/lib/progress-bar.component.ts","../../../../libs/components/progress-bar/src/lib/progress-bar.component.html","../../../../libs/components/progress-bar/src/lib/progress-bar.module.ts","../../../../libs/components/progress-bar/src/acorex-components-progress-bar.ts"],"sourcesContent":["import { MXColorComponent } from '@acorex/components/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n EventEmitter,\n HostBinding,\n Input,\n Output,\n ViewChild,\n ViewEncapsulation,\n} from '@angular/core';\n\n/**\n * The Button is a component which detects user interaction and triggers a corresponding event\n *\n * @category Components\n */\n\nexport type AXProgressMode = 'determinate' | 'indeterminate' | 'buffer' | 'query';\n\n@Component({\n selector: 'ax-progress-bar',\n templateUrl: './progress-bar.component.html',\n styleUrls: ['./progress-bar.component.scss'],\n inputs: ['color'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n})\nexport class AXProgressBarComponent extends MXColorComponent {\n\n /** @ignore */\n @ViewChild('c') circle: ElementRef;\n\n /**\n * @event\n * Emits when the slider value changes.\n */\n @Output()\n ValueChange: EventEmitter<number> = new EventEmitter();\n\n /** @ignore */\n private _progress = 0;\n\n /**\n * Specifies the progress indicator mode.\n */\n @Input()\n mode: AXProgressMode = 'determinate';\n\n /**\n * Gets or sets the progress value (0-100).\n */\n @Input()\n \n /**\n * Retrieves the current progress value (0-100).\n */\n public get progress(): number {\n return this._progress;\n }\n\n /**\n * Sets the progress value (0-100).\n * @param {number} v\n */\n public set progress(v: number) {\n this.setOption({\n name: 'progress',\n value: v,\n });\n }\n\n /**\n * Emitted when the size changes.\n * @event\n */\n @Output()\n sizeChange: EventEmitter<number> = new EventEmitter();\n\n /** @ignore */\n private _height = 8;\n\n /**\n * Gets or sets the height of the component.\n * @param {number} v\n */\n @Input()\n\n /**\n * Gets the height of the component.\n */\n public get height(): number {\n return this._height;\n }\n\n /**\n * Sets the height of the component.\n * @param {number} v\n */\n public set height(v: number) {\n this.setOption({\n name: 'height',\n value: v,\n });\n }\n\n /** @ignore */\n @HostBinding('class')\n private get __hostClass(): string {\n return `ax-${this['color']}-appearance`;\n }\n}\n","<ng-content select=\"ax-prefix\"></ng-content>\n@switch (mode) {\n\n@case ('indeterminate') {\n<div class=\"ax-progress\" [style.height.px]=\"height\" role=\"progressbar\">\n <div class=\"ax-progress-bar ax-indeterminate-progress\"></div>\n</div>\n}\n@case ('query') {\n<div class=\"ax-progress\" [style.height.px]=\"height\" role=\"progressbar\">\n <div class=\"ax-progress-bar ax-query-progress\"></div>\n</div>\n}\n@case ('buffer') {\n<div class=\"ax-progress \" [style.height.px]=\"height\" role=\"progressbar\">\n <div class=\"ax-progress-bar ax-buffer-progress\"></div>\n</div>\n}\n@default {\n<div class=\"ax-progress\" [style.height.px]=\"height\" role=\"progressbar\">\n <div class=\"ax-progress-bar\" [style.width.%]=\"progress\"></div>\n</div>\n}\n\n}\n<ng-content select=\"ax-suffix\"></ng-content>\n\n<!--TODO: impliment other modes-->","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { AXProgressBarComponent } from './progress-bar.component';\n\n@NgModule({\n declarations: [AXProgressBarComponent],\n imports: [CommonModule],\n exports: [AXProgressBarComponent],\n providers: [],\n})\nexport class AXProgressBarModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;AA6BM,MAAO,sBAAuB,SAAQ,gBAAgB,CAAA;AAR5D,IA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YAAA,IAAA,EAAA,CAAA;oBACR,YAAY,EAAE,CAAC,sBAAsB,CAAC;oBACtC,OAAO,EAAE,CAAC,YAAY,CAAC;oBACvB,OAAO,EAAE,CAAC,sBAAsB,CAAC;AACjC,oBAAA,SAAS,EAAE,EAAE;AACd,iBAAA;;;ACTD;;AAEG;;;;"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"acorex-components-qrcode.mjs","sources":["../../../../libs/components/qrcode/src/lib/qrcode.class.ts","../../../../libs/components/qrcode/src/lib/qrcode.component.ts","../../../../libs/components/qrcode/src/lib/qrcode.component.html","../../../../libs/components/qrcode/src/lib/qrcode.module.ts","../../../../libs/components/qrcode/src/acorex-components-qrcode.ts"],"sourcesContent":["export type AXQrcodeOutputType = 'canvas' | 'svg' | 'url';\nexport type AXQrcodeLevel = 'L' | 'M' | 'Q' | 'H';\n\nexport function debounce(func: (...args: any) => void, delayMS: number) {\n let timeoutId;\n\n return function (...args) {\n if (timeoutId) {\n clearTimeout(timeoutId);\n }\n timeoutId = setTimeout(() => {\n func(...args);\n }, delayMS);\n };\n}\n","import { generateQRCode } from '@acorex/cdk/qrcode';\nimport { AXValuableComponent } from '@acorex/components/common';\nimport {\n AfterViewInit,\n ChangeDetectionStrategy,\n Component,\n effect,\n ElementRef,\n forwardRef,\n input,\n signal,\n viewChild,\n ViewEncapsulation,\n} from '@angular/core';\nimport { NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { AXQrcodeLevel, AXQrcodeOutputType } from './qrcode.class';\n\n@Component({\n selector: 'ax-qrcode',\n templateUrl: './qrcode.component.html',\n styleUrls: ['./qrcode.component.scss'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [\n { provide: AXValuableComponent, useExisting: AXQrcodeComponent },\n {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => AXQrcodeComponent),\n multi: true,\n },\n ],\n})\nexport class AXQrcodeComponent implements AfterViewInit {\n /**\n * @description Value of QR code\n */\n content = input.required<string>();\n /**\n * @description Size of the QR code\n * @default 256\n */\n size = input(256);\n /**\n * @description Error correction level can be 'L' | 'M' | 'Q' | 'H'\n * @default 'M'\n */\n level = input<AXQrcodeLevel>('M');\n /**\n * @description QR code color, can be a hex code or CSS color name\n * @default '#000000'\n */\n color = input('#000000');\n /**\n * @description QR code Background color, can be a hex code or CSS color name\n * @default '#FFFFFF'\n */\n backgroundColor = input('#FFFFFF');\n /**\n * @description Type of output can be 'canvas' | 'svg' | 'url'\n * @default 'canvas'\n */\n outputType = input<AXQrcodeOutputType>('canvas'); //\n /**\n * @ignore\n */\n /**\n * @description // Holds base64 or URL if outputType is 'url' or 'base64'\n */\n protected qrCodeUrl = signal<string | undefined>(undefined);\n /**\n * @ignore\n */\n private canvas = viewChild<ElementRef<HTMLCanvasElement>>('canvas');\n /**\n * @ignore\n */\n private svg = viewChild<ElementRef<HTMLCanvasElement>>('svg');\n\n constructor() {\n effect(\n () => {\n this.generate();\n },\n {\n allowSignalWrites: true,\n },\n );\n }\n\n ngAfterViewInit() {\n this.generate();\n }\n generate() {\n generateQRCode(\n this.content(),\n this.size(),\n this.level(),\n this.color(),\n this.backgroundColor(),\n this.outputType(),\n this.canvas()?.nativeElement,\n this.svg()?.nativeElement,\n )\n .then((result) => {\n if (this.outputType() === 'url') {\n this.qrCodeUrl.set(result as string);\n }\n })\n .catch((error) => {\n console.error(error);\n });\n }\n}\n","<div class=\"qrcode\">\n @if (outputType() === 'canvas') {\n <canvas #canvas></canvas>\n } @else if (outputType() === 'svg') {\n <div #svg></div>\n } @else {\n <img [src]=\"qrCodeUrl()\" alt=\"QR Code\" />\n }\n <div class=\"logo-container\">\n <ng-content select=\"img\"></ng-content>\n </div>\n</div>\n","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { AXQrcodeComponent } from './qrcode.component';\n\n@NgModule({\n declarations: [AXQrcodeComponent],\n imports: [CommonModule],\n exports: [AXQrcodeComponent],\n})\nexport class AXQrcodeModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;AAGgB,SAAA,QAAQ,CAAC,IAA4B,EAAE,OAAe,EAAA;AACpE,IAAA,IAAI,SAAS
|
1
|
+
{"version":3,"file":"acorex-components-qrcode.mjs","sources":["../../../../libs/components/qrcode/src/lib/qrcode.class.ts","../../../../libs/components/qrcode/src/lib/qrcode.component.ts","../../../../libs/components/qrcode/src/lib/qrcode.component.html","../../../../libs/components/qrcode/src/lib/qrcode.module.ts","../../../../libs/components/qrcode/src/acorex-components-qrcode.ts"],"sourcesContent":["export type AXQrcodeOutputType = 'canvas' | 'svg' | 'url';\nexport type AXQrcodeLevel = 'L' | 'M' | 'Q' | 'H';\n\nexport function debounce(func: (...args: any) => void, delayMS: number) {\n let timeoutId;\n\n return function (...args) {\n if (timeoutId) {\n clearTimeout(timeoutId);\n }\n timeoutId = setTimeout(() => {\n func(...args);\n }, delayMS);\n };\n}\n","import { generateQRCode } from '@acorex/cdk/qrcode';\nimport { AXValuableComponent } from '@acorex/components/common';\nimport {\n AfterViewInit,\n ChangeDetectionStrategy,\n Component,\n effect,\n ElementRef,\n forwardRef,\n input,\n signal,\n viewChild,\n ViewEncapsulation,\n} from '@angular/core';\nimport { NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { AXQrcodeLevel, AXQrcodeOutputType } from './qrcode.class';\n\n@Component({\n selector: 'ax-qrcode',\n templateUrl: './qrcode.component.html',\n styleUrls: ['./qrcode.component.scss'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [\n { provide: AXValuableComponent, useExisting: AXQrcodeComponent },\n {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => AXQrcodeComponent),\n multi: true,\n },\n ],\n})\nexport class AXQrcodeComponent implements AfterViewInit {\n /**\n * @description Value of QR code\n */\n content = input.required<string>();\n /**\n * @description Size of the QR code\n * @default 256\n */\n size = input(256);\n /**\n * @description Error correction level can be 'L' | 'M' | 'Q' | 'H'\n * @default 'M'\n */\n level = input<AXQrcodeLevel>('M');\n /**\n * @description QR code color, can be a hex code or CSS color name\n * @default '#000000'\n */\n color = input('#000000');\n /**\n * @description QR code Background color, can be a hex code or CSS color name\n * @default '#FFFFFF'\n */\n backgroundColor = input('#FFFFFF');\n /**\n * @description Type of output can be 'canvas' | 'svg' | 'url'\n * @default 'canvas'\n */\n outputType = input<AXQrcodeOutputType>('canvas'); //\n /**\n * @ignore\n */\n /**\n * @description // Holds base64 or URL if outputType is 'url' or 'base64'\n */\n protected qrCodeUrl = signal<string | undefined>(undefined);\n /**\n * @ignore\n */\n private canvas = viewChild<ElementRef<HTMLCanvasElement>>('canvas');\n /**\n * @ignore\n */\n private svg = viewChild<ElementRef<HTMLCanvasElement>>('svg');\n\n constructor() {\n effect(\n () => {\n this.generate();\n },\n {\n allowSignalWrites: true,\n },\n );\n }\n\n ngAfterViewInit() {\n this.generate();\n }\n generate() {\n generateQRCode(\n this.content(),\n this.size(),\n this.level(),\n this.color(),\n this.backgroundColor(),\n this.outputType(),\n this.canvas()?.nativeElement,\n this.svg()?.nativeElement,\n )\n .then((result) => {\n if (this.outputType() === 'url') {\n this.qrCodeUrl.set(result as string);\n }\n })\n .catch((error) => {\n console.error(error);\n });\n }\n}\n","<div class=\"qrcode\">\n @if (outputType() === 'canvas') {\n <canvas #canvas></canvas>\n } @else if (outputType() === 'svg') {\n <div #svg></div>\n } @else {\n <img [src]=\"qrCodeUrl()\" alt=\"QR Code\" />\n }\n <div class=\"logo-container\">\n <ng-content select=\"img\"></ng-content>\n </div>\n</div>\n","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { AXQrcodeComponent } from './qrcode.component';\n\n@NgModule({\n declarations: [AXQrcodeComponent],\n imports: [CommonModule],\n exports: [AXQrcodeComponent],\n})\nexport class AXQrcodeModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"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AY,CAAC;oBACvB,OAAO,EAAE,CAAC,iBAAiB,CAAC;AAC7B,iBAAA;;;ACRD;;AAEG;;;;"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"acorex-components-radio.mjs","sources":["../../../../libs/components/radio/src/lib/radio.component.ts","../../../../libs/components/radio/src/lib/radio.component.html","../../../../libs/components/radio/src/lib/radio.module.ts","../../../../libs/components/radio/src/acorex-components-radio.ts"],"sourcesContent":["import { MXValueComponent } from '@acorex/components/common';\nimport { AXLabelComponent } from '@acorex/components/label';\nimport {\n AfterViewChecked,\n ChangeDetectionStrategy,\n Component,\n ContentChildren,\n HostListener,\n QueryList,\n ViewEncapsulation,\n forwardRef,\n} from '@angular/core';\nimport { NG_VALUE_ACCESSOR } from '@angular/forms';\n\n/**\n * The Button is a component which detects user interaction and triggers a corresponding event\n *\n * @category\n */\n@Component({\n selector: 'ax-radio',\n templateUrl: './radio.component.html',\n styleUrls: ['./radio.component.scss'],\n inputs: ['disabled', 'tabIndex', 'readonly', 'value', 'name', 'id', 'checked'],\n outputs: ['onBlur', 'onFocus', 'valueChange', 'onValueChanged'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n providers: [\n {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => AXRadioComponent),\n multi: true,\n },\n ],\n})\nexport class AXRadioComponent extends MXValueComponent<boolean | null> implements AfterViewChecked {\n\n /** @ignore */\n @ContentChildren(AXLabelComponent)\n\n /** @ignore */\n private _labels: QueryList<AXLabelComponent>;\n\n /** @ignore */\n ngAfterViewChecked() {\n this._labels?.forEach((c) => {\n c.for = this;\n });\n }\n\n /** @ignore */\n @HostListener('click', ['$event'])\n\n /** @ignore */\n private _handleClick(e: UIEvent) {\n e.stopPropagation();\n if (this.readonly || this.disabled) {\n e.preventDefault();\n return false;\n }\n return true;\n }\n\n /** @ignore */\n protected _handleModelChange(value: boolean | null) {\n this.commitValue(value, true);\n }\n}\n","<!-- <div class=\"ax-checkbox-label\">\n <div class=\"ax-checkbox-start-side\">\n <input [id]=\"id\" class=\"ax-radio\" type=\"radio\" [(ngModel)]=\"value\" [checked]=\"value\" [disabled]=\"disabled\"\n [readonly]=\"readonly\" [tabindex]=\"tabIndex\" (click)=\"_handleOnClickEvent($event)\"\n (focus)=\"_emitOnFocusEvent($event)\" (blur)=\"_emitOnBlurEvent($event)\">\n </div>\n <div class=\"ax-checkbox-end-side\">\n <ng-content select=\"ax-label\"></ng-content>\n <ng-content select=\"ax-form-hint\"></ng-content>\n </div>\n</div>\n<ng-content select=\"ax-validation-rule\"></ng-content> -->\n\n\n\n\n<div class=\"ax-radio-label\" [class.ax-state-readonly]=\"readonly\" [class.ax-state-disabled]=\"disabled\">\n <div class=\"ax-radio-start-side\">\n <!-- <input [id]=\"id\" class=\"ax-radio\" type=\"radio\" [indeterminate]=\"_stateIndeterminate\" [ngModel]=\"value\"\n (ngModelChange)=\"_handleModelChange($event)\" [checked]=\"value\" [disabled]=\"disabled\" [readonly]=\"readonly\"\n [tabindex]=\"tabIndex\" (focus)=\"emitOnFocusEvent($event)\" (blur)=\"emitOnBlurEvent($event)\"> -->\n\n <input [id]=\"id\" class=\"ax-radio\" type=\"radio\" [ngModel]=\"value\" [checked]=\"value\" [disabled]=\"disabled\"\n [readonly]=\"readonly\" [tabindex]=\"tabIndex\" (ngModelChange)=\"_handleModelChange($event)\"\n (focus)=\"emitOnFocusEvent($event)\" (blur)=\"emitOnBlurEvent($event)\">\n </div>\n <div class=\"ax-radio-end-side\">\n <ng-content select=\"ax-label\"></ng-content>\n <ng-content select=\"ax-form-hint\"></ng-content>\n <span class=\"ax-error-container\"></span>\n </div>\n</div>\n<ng-content select=\"ax-validation-rule\"></ng-content>","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { FormsModule } from '@angular/forms';\nimport { AXRadioComponent } from './radio.component';\n\nconst COMPONENT = [AXRadioComponent];\nconst MODULES = [CommonModule, FormsModule];\n\n@NgModule({\n declarations: [...COMPONENT],\n imports: [...MODULES],\n exports: [...COMPONENT],\n providers: [],\n})\nexport class AXRadioModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;AAcA;;;;AAIG;AAiBG,MAAO,gBAAiB,SAAQ,gBAAgC,CAAA;;IASpE,kBAAkB,GAAA;QAChB,IAAI,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC,KAAI;AAC1B,YAAA,CAAC,CAAC,GAAG,GAAG,IAAI
|
1
|
+
{"version":3,"file":"acorex-components-radio.mjs","sources":["../../../../libs/components/radio/src/lib/radio.component.ts","../../../../libs/components/radio/src/lib/radio.component.html","../../../../libs/components/radio/src/lib/radio.module.ts","../../../../libs/components/radio/src/acorex-components-radio.ts"],"sourcesContent":["import { MXValueComponent } from '@acorex/components/common';\nimport { AXLabelComponent } from '@acorex/components/label';\nimport {\n AfterViewChecked,\n ChangeDetectionStrategy,\n Component,\n ContentChildren,\n HostListener,\n QueryList,\n ViewEncapsulation,\n forwardRef,\n} from '@angular/core';\nimport { NG_VALUE_ACCESSOR } from '@angular/forms';\n\n/**\n * The Button is a component which detects user interaction and triggers a corresponding event\n *\n * @category\n */\n@Component({\n selector: 'ax-radio',\n templateUrl: './radio.component.html',\n styleUrls: ['./radio.component.scss'],\n inputs: ['disabled', 'tabIndex', 'readonly', 'value', 'name', 'id', 'checked'],\n outputs: ['onBlur', 'onFocus', 'valueChange', 'onValueChanged'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n providers: [\n {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => AXRadioComponent),\n multi: true,\n },\n ],\n})\nexport class AXRadioComponent extends MXValueComponent<boolean | null> implements AfterViewChecked {\n\n /** @ignore */\n @ContentChildren(AXLabelComponent)\n\n /** @ignore */\n private _labels: QueryList<AXLabelComponent>;\n\n /** @ignore */\n ngAfterViewChecked() {\n this._labels?.forEach((c) => {\n c.for = this;\n });\n }\n\n /** @ignore */\n @HostListener('click', ['$event'])\n\n /** @ignore */\n private _handleClick(e: UIEvent) {\n e.stopPropagation();\n if (this.readonly || this.disabled) {\n e.preventDefault();\n return false;\n }\n return true;\n }\n\n /** @ignore */\n protected _handleModelChange(value: boolean | null) {\n this.commitValue(value, true);\n }\n}\n","<!-- <div class=\"ax-checkbox-label\">\n <div class=\"ax-checkbox-start-side\">\n <input [id]=\"id\" class=\"ax-radio\" type=\"radio\" [(ngModel)]=\"value\" [checked]=\"value\" [disabled]=\"disabled\"\n [readonly]=\"readonly\" [tabindex]=\"tabIndex\" (click)=\"_handleOnClickEvent($event)\"\n (focus)=\"_emitOnFocusEvent($event)\" (blur)=\"_emitOnBlurEvent($event)\">\n </div>\n <div class=\"ax-checkbox-end-side\">\n <ng-content select=\"ax-label\"></ng-content>\n <ng-content select=\"ax-form-hint\"></ng-content>\n </div>\n</div>\n<ng-content select=\"ax-validation-rule\"></ng-content> -->\n\n\n\n\n<div class=\"ax-radio-label\" [class.ax-state-readonly]=\"readonly\" [class.ax-state-disabled]=\"disabled\">\n <div class=\"ax-radio-start-side\">\n <!-- <input [id]=\"id\" class=\"ax-radio\" type=\"radio\" [indeterminate]=\"_stateIndeterminate\" [ngModel]=\"value\"\n (ngModelChange)=\"_handleModelChange($event)\" [checked]=\"value\" [disabled]=\"disabled\" [readonly]=\"readonly\"\n [tabindex]=\"tabIndex\" (focus)=\"emitOnFocusEvent($event)\" (blur)=\"emitOnBlurEvent($event)\"> -->\n\n <input [id]=\"id\" class=\"ax-radio\" type=\"radio\" [ngModel]=\"value\" [checked]=\"value\" [disabled]=\"disabled\"\n [readonly]=\"readonly\" [tabindex]=\"tabIndex\" (ngModelChange)=\"_handleModelChange($event)\"\n (focus)=\"emitOnFocusEvent($event)\" (blur)=\"emitOnBlurEvent($event)\">\n </div>\n <div class=\"ax-radio-end-side\">\n <ng-content select=\"ax-label\"></ng-content>\n <ng-content select=\"ax-form-hint\"></ng-content>\n <span class=\"ax-error-container\"></span>\n </div>\n</div>\n<ng-content select=\"ax-validation-rule\"></ng-content>","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { FormsModule } from '@angular/forms';\nimport { AXRadioComponent } from './radio.component';\n\nconst COMPONENT = [AXRadioComponent];\nconst MODULES = [CommonModule, FormsModule];\n\n@NgModule({\n declarations: [...COMPONENT],\n imports: [...MODULES],\n exports: [...COMPONENT],\n providers: [],\n})\nexport class AXRadioModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;AAcA;;;;AAIG;AAiBG,MAAO,gBAAiB,SAAQ,gBAAgC,CAAA;;IASpE,kBAAkB,GAAA;QAChB,IAAI,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC,CAAC,KAAI;AAC1B,YAAA,CAAC,CAAC,GAAG,GAAG,IAAI;AACd,SAAC,CAAC;;;AAOI,IAAA,YAAY,CAAC,CAAU,EAAA;QAC7B,CAAC,CAAC,eAAe,EAAE;QACnB,IAAI,IAAI,CAAC,QAAQ,IAAI,IAAI,CAAC,QAAQ,EAAE;YAClC,CAAC,CAAC,cAAc,EAAE;AAClB,YAAA,OAAO,KAAK;;AAEd,QAAA,OAAO,IAAI;;;AAIH,IAAA,kBAAkB,CAAC,KAAqB,EAAA;AAChD,QAAA,IAAI,CAAC,WAAW,CAAC,KAAK,EAAE,IAAI,CAAC;;8GA9BpB,gBAAgB,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAhB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,gBAAgB,EARhB,QAAA,EAAA,UAAA,EAAA,MAAA,EAAA,EAAA,QAAA,EAAA,UAAA,EAAA,QAAA,EAAA,U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