@acorex/components 18.14.1-next.5 → 18.15.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (82) hide show
  1. package/comment/lib/comment-container/comment-container.component.d.ts +1 -0
  2. package/common/lib/components/value-component.class.d.ts +1 -0
  3. package/common/lib/directives/auto-focus.directive.d.ts +1 -0
  4. package/common/lib/directives/ripple.directive.d.ts +1 -0
  5. package/data-table/lib/columns/data-table-column-resizable.directive.d.ts +1 -0
  6. package/data-table/lib/data-table/data-table.component.d.ts +61 -60
  7. package/data-table/lib/infinite-scroll-data-table/infinite-scroll-data-table.component.d.ts +7 -6
  8. package/drawer/lib/drawer/drawer-item/drawer.component.d.ts +2 -0
  9. package/esm2022/audio-wave/lib/audio-wave.component.mjs +79 -14
  10. package/esm2022/avatar/lib/avatar.component.mjs +2 -2
  11. package/esm2022/button/lib/button.component.mjs +2 -2
  12. package/esm2022/calendar/lib/calendar-range.component.mjs +2 -2
  13. package/esm2022/calendar/lib/calendar.component.mjs +3 -3
  14. package/esm2022/comment/lib/comment-container/comment-container.component.mjs +7 -3
  15. package/esm2022/common/lib/components/value-component.class.mjs +4 -2
  16. package/esm2022/common/lib/directives/auto-focus.directive.mjs +5 -3
  17. package/esm2022/common/lib/directives/inverted-color.directive.mjs +1 -1
  18. package/esm2022/common/lib/directives/ripple.directive.mjs +5 -3
  19. package/esm2022/conversation/lib/conversation-message/conversation-message.component.mjs +2 -2
  20. package/esm2022/conversation/lib/conversation-messages/conversation-message-voice/conversation-message-voice.component.mjs +2 -2
  21. package/esm2022/cron-job/index.mjs +1 -1
  22. package/esm2022/cron-job/lib/cron-job-container/cron-job-container.component.mjs +3 -3
  23. package/esm2022/cron-job/lib/day/day.component.mjs +3 -3
  24. package/esm2022/cron-job/lib/hours/hours.component.mjs +3 -3
  25. package/esm2022/cron-job/lib/minutes/minutes.component.mjs +3 -3
  26. package/esm2022/cron-job/lib/month/month.component.mjs +3 -3
  27. package/esm2022/cron-job/lib/seconds/seconds.component.mjs +3 -3
  28. package/esm2022/cron-job/lib/year/year.component.mjs +3 -3
  29. package/esm2022/data-table/lib/columns/data-table-column-resizable.directive.mjs +9 -7
  30. package/esm2022/data-table/lib/data-table/data-table.component.mjs +71 -67
  31. package/esm2022/data-table/lib/infinite-scroll-data-table/infinite-scroll-data-table.component.mjs +16 -11
  32. package/esm2022/drawer/lib/drawer/drawer-item/drawer.component.mjs +5 -2
  33. package/esm2022/list/lib/list.component.mjs +17 -5
  34. package/esm2022/loading/lib/loading-spinner.component.mjs +2 -2
  35. package/esm2022/loading-dialog/lib/loading-dialog.component.mjs +2 -2
  36. package/esm2022/menu/lib/context-menu.component.mjs +28 -21
  37. package/esm2022/password-box/lib/password-box.component.mjs +13 -5
  38. package/esm2022/password-box/lib/password-box.module.mjs +19 -3
  39. package/esm2022/password-box/lib/password-strength-validation/password-strength-validation.component.mjs +36 -14
  40. package/esm2022/popover/lib/popover.component.mjs +5 -3
  41. package/esm2022/popup/lib/popup.component.mjs +2 -2
  42. package/esm2022/uploader/lib/uploader-zone.directive.mjs +7 -5
  43. package/fesm2022/acorex-components-audio-wave.mjs +78 -13
  44. package/fesm2022/acorex-components-audio-wave.mjs.map +1 -1
  45. package/fesm2022/acorex-components-avatar.mjs +2 -2
  46. package/fesm2022/acorex-components-avatar.mjs.map +1 -1
  47. package/fesm2022/acorex-components-button.mjs +2 -2
  48. package/fesm2022/acorex-components-calendar.mjs +4 -4
  49. package/fesm2022/acorex-components-calendar.mjs.map +1 -1
  50. package/fesm2022/acorex-components-comment.mjs +7 -4
  51. package/fesm2022/acorex-components-comment.mjs.map +1 -1
  52. package/fesm2022/acorex-components-common.mjs +6 -3
  53. package/fesm2022/acorex-components-common.mjs.map +1 -1
  54. package/fesm2022/acorex-components-conversation.mjs +2 -2
  55. package/fesm2022/acorex-components-conversation.mjs.map +1 -1
  56. package/fesm2022/acorex-components-cron-job.mjs +14 -14
  57. package/fesm2022/acorex-components-cron-job.mjs.map +1 -1
  58. package/fesm2022/acorex-components-data-table.mjs +89 -81
  59. package/fesm2022/acorex-components-data-table.mjs.map +1 -1
  60. package/fesm2022/acorex-components-drawer.mjs +4 -2
  61. package/fesm2022/acorex-components-drawer.mjs.map +1 -1
  62. package/fesm2022/acorex-components-list.mjs +16 -4
  63. package/fesm2022/acorex-components-list.mjs.map +1 -1
  64. package/fesm2022/acorex-components-loading-dialog.mjs +2 -2
  65. package/fesm2022/acorex-components-loading.mjs +2 -2
  66. package/fesm2022/acorex-components-loading.mjs.map +1 -1
  67. package/fesm2022/acorex-components-menu.mjs +24 -18
  68. package/fesm2022/acorex-components-menu.mjs.map +1 -1
  69. package/fesm2022/acorex-components-password-box.mjs +65 -19
  70. package/fesm2022/acorex-components-password-box.mjs.map +1 -1
  71. package/fesm2022/acorex-components-popover.mjs +4 -3
  72. package/fesm2022/acorex-components-popover.mjs.map +1 -1
  73. package/fesm2022/acorex-components-popup.mjs +2 -2
  74. package/fesm2022/acorex-components-uploader.mjs +7 -6
  75. package/fesm2022/acorex-components-uploader.mjs.map +1 -1
  76. package/menu/lib/context-menu.component.d.ts +2 -1
  77. package/package.json +1 -1
  78. package/password-box/lib/password-box.component.d.ts +9 -1
  79. package/password-box/lib/password-box.module.d.ts +3 -1
  80. package/password-box/lib/password-strength-validation/password-strength-validation.component.d.ts +23 -1
  81. package/popover/lib/popover.component.d.ts +1 -0
  82. package/uploader/lib/uploader-zone.directive.d.ts +1 -0
@@ -1 +1 @@
1
- {"version":3,"file":"acorex-components-menu.mjs","sources":["../../../../libs/components/menu/src/lib/menu.types.ts","../../../../libs/components/menu/src/lib/menu.service.ts","../../../../libs/components/menu/src/lib/menu-item.component.ts","../../../../libs/components/menu/src/lib/menu-item.component.html","../../../../libs/components/menu/src/lib/context-menu.component.ts","../../../../libs/components/menu/src/lib/menu.component.html","../../../../libs/components/menu/src/lib/menu.component.ts","../../../../libs/components/menu/src/lib/menu.module.ts","../../../../libs/components/menu/src/acorex-components-menu.ts"],"sourcesContent":["import { AXOrientation, AXStyleColorType, NXClickEvent, NXComponent } from '@acorex/components/common';\nimport { OutputEmitterRef, WritableSignal } from '@angular/core';\n\nexport type AXMenuOpenTrigger = 'click' | 'hover';\nexport type AXMenuCloseTrigger = 'click' | 'leave';\n\nexport abstract class AXRootMenu {\n orientation: WritableSignal<AXOrientation>;\n openOn: WritableSignal<AXMenuOpenTrigger>;\n closeOn: WritableSignal<AXMenuCloseTrigger>;\n onItemClick: OutputEmitterRef<AXMenuItemClickBaseEvent>;\n nativeElement: HTMLDivElement;\n hasArrow: WritableSignal<boolean>;\n}\n\nexport abstract class AXMenuItemComponentBase {}\n\nexport abstract class AXMenuItem {\n color?: AXStyleColorType;\n name?: string;\n text: string;\n data?: any;\n icon?: string;\n disabled?: boolean;\n items?: AXMenuItem[];\n suffix?: {\n text: string;\n };\n break?: boolean;\n group?: {\n name?: string;\n title?: string;\n };\n}\n\nexport class AXMenuItemClickBaseEvent<T extends NXComponent = NXComponent> extends NXClickEvent<T> {\n item: {\n name?: string;\n text: string;\n data?: any;\n };\n canceled = false;\n}\n","import { Injectable } from '@angular/core';\nimport { Subject } from 'rxjs';\nimport { AXMenuItemComponentBase, AXRootMenu } from './menu.types';\nimport { AXPoint } from '@acorex/core/utils';\n\n@Injectable()\nexport class AXMenuService {\n public closeAll$: Subject<void> = new Subject();\n public open$: Subject<AXMenuItemComponentBase> = new Subject();\n public close$: Subject<AXMenuItemComponentBase> = new Subject();\n public closeExcept$ = new Subject<AXMenuItemComponentBase>();\n\n public openContextMenu$ = new Subject<{ sender: AXRootMenu, point: AXPoint }>();\n public closeAllContextMenu$ = new Subject<{ sender: AXRootMenu }>();\n}\n","import { AXStyleColorType, NXComponent } from '@acorex/components/common';\nimport { AXHtmlUtil, AXUnsubscriber } from '@acorex/core/utils';\nimport {\n afterNextRender,\n ChangeDetectionStrategy,\n Component,\n computed,\n HostBinding,\n HostListener,\n inject,\n input,\n output,\n Renderer2,\n signal,\n ViewEncapsulation,\n} from '@angular/core';\nimport { AXMenuService } from './menu.service';\nimport { AXMenuItemClickBaseEvent, AXMenuItemComponentBase, AXRootMenu } from './menu.types';\n\nexport type AXMenuItemClickEvent = AXMenuItemClickBaseEvent<AXMenuItemComponent>;\n\n/**\n * Represents a menu item component used within an `ax-menu`.\n * @category Components\n */\n@Component({\n selector: 'ax-menu-item',\n templateUrl: './menu-item.component.html',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [\n {\n provide: AXMenuItemComponentBase,\n useExisting: AXMenuItemComponent,\n },\n AXUnsubscriber,\n ],\n})\nexport class AXMenuItemComponent extends NXComponent {\n protected isOpen = signal(false);\n protected hasSubItems = signal(false);\n protected isFirstLevel = signal(false);\n private mutationObserver!: MutationObserver;\n\n protected root = inject(AXRootMenu);\n protected parent?: AXMenuItemComponent | null;\n protected isRoot = () => this.parent == null;\n\n private service = inject(AXMenuService);\n private scrollableParents: HTMLElement[] = [];\n\n private unsuscriber = inject(AXUnsubscriber);\n private renderer = inject(Renderer2);\n\n protected arrowIcon = computed(() => {\n const isRtl = AXHtmlUtil.isRtl(this.nativeElement);\n return this.root.orientation() == 'horizontal' && this.isFirstLevel()\n ? 'ax-icon-chevron-down'\n : isRtl\n ? 'ax-icon-chevron-left'\n : 'ax-icon-chevron-right';\n });\n\n onClick = output<AXMenuItemClickEvent>();\n\n name = input<string>();\n data = input<any>();\n disabled = input<boolean>();\n color = input<AXStyleColorType>();\n\n constructor() {\n super();\n //\n afterNextRender(() => {\n this.detectSubItems();\n this.observeMutations();\n this.bindScrollEvents();\n });\n //\n this.service.closeAll$.pipe(this.unsuscriber.takeUntilDestroy).subscribe(() => this.close());\n\n this.service.open$.pipe(this.unsuscriber.takeUntilDestroy).subscribe((item) => {\n if ((this as any) === item) {\n this.isOpen.set(true);\n this.calculatePosition();\n }\n });\n //\n this.service.close$.pipe(this.unsuscriber.takeUntilDestroy).subscribe((item) => {\n if ((this as any) == item) {\n this.isOpen.set(false);\n }\n });\n //\n this.service.closeExcept$.pipe(this.unsuscriber.takeUntilDestroy).subscribe((item) => {\n this.closeExcept(item as AXMenuItemComponent);\n });\n }\n\n private closeExcept(item: AXMenuItemComponent) {\n const list: AXMenuItemComponent[] = [item];\n //\n let parent = item.parent;\n while (parent != null) {\n list.push(parent);\n parent = parent.parent;\n }\n //\n if (!list.includes(this)) {\n this.close();\n }\n }\n\n private observeMutations() {\n this.mutationObserver = new MutationObserver(() => {\n this.detectSubItems();\n });\n\n // Start observing changes in child elements\n this.mutationObserver.observe(this.nativeElement, {\n childList: true,\n subtree: true,\n });\n }\n\n private getText(): string {\n return this.nativeElement.querySelector<HTMLDivElement>('ax-text')?.innerText;\n }\n\n /**\n * Manually detect all `ax-menu-item` elements and check if this menu item has sub-items.\n */\n private detectSubItems() {\n //\n const parentEl = this.nativeElement.parentElement?.parentElement;\n this.parent =\n parentEl?.tagName == 'AX-MENU-ITEM' ? (parentEl?.['__axContext__'] as AXMenuItemComponent) : null;\n //\n const tag = this.nativeElement.parentElement?.tagName;\n this.isFirstLevel.set(tag == 'AX-MENU' || tag == 'AX-CONTEXT-MENU');\n const subItems = this.nativeElement.querySelectorAll('ax-menu-item');\n if (subItems.length > 0) {\n this.hasSubItems.set(true);\n } else {\n this.hasSubItems.set(false);\n }\n }\n\n open() {\n this.service.closeExcept$.next(this);\n if (!this.disabled() && this.hasSubItems()) {\n this.service.open$.next(this);\n }\n }\n\n close() {\n this.service.close$.next(this);\n }\n\n /**\n * Calculate the position of the submenu to avoid it going out of the viewport.\n */\n private calculatePosition() {\n const submenu = this.nativeElement.querySelector('.ax-menu-items');\n if (!submenu) return;\n\n const submenuRect = submenu.getBoundingClientRect();\n const itemRect = this.nativeElement.getBoundingClientRect();\n const windowWidth = window.innerWidth;\n const windowHeight = window.innerHeight;\n\n const isRtl = AXHtmlUtil.isRtl(this.nativeElement);\n\n let top: number | null = null;\n let left: number | null = null;\n\n // For first-level menu items\n if (this.isFirstLevel() && this.root.orientation() === 'horizontal') {\n top =\n itemRect.bottom + submenuRect.height > windowHeight\n ? itemRect.top - submenuRect.height // Open upwards\n : itemRect.bottom; // Open downwards\n\n if (isRtl) {\n // RTL: Align to the right of the parent item\n left =\n itemRect.right - submenuRect.width < 0\n ? itemRect.left // Align to the left if not enough space on the right\n : itemRect.right - submenuRect.width; // Open to the left in RTL\n } else {\n // LTR: Align to the left of the parent item\n left =\n itemRect.left + submenuRect.width > windowWidth\n ? itemRect.right - submenuRect.width // Align to the right edge in LTR\n : itemRect.left; // Open to the left\n }\n } else {\n // For nested submenus\n if (isRtl) {\n // RTL: Nested submenu opens to the left\n left =\n itemRect.left - submenuRect.width < 0\n ? itemRect.right // Align to the right if not enough space on the left\n : itemRect.left - submenuRect.width; // Open to the left in RTL\n } else {\n // LTR: Nested submenu opens to the right\n left =\n itemRect.right + submenuRect.width > windowWidth\n ? itemRect.left - submenuRect.width // Open to the left if not enough space\n : itemRect.right; // Open to the right in LTR\n }\n\n // Adjust top position (align vertically with parent)\n top =\n itemRect.top + submenuRect.height > windowHeight\n ? itemRect.top - (itemRect.bottom + submenuRect.height - windowHeight) // Adjust upwards\n : itemRect.top; // Align with the parent item\n }\n\n // Apply calculated styles for RTL/LTR\n this.renderer.setStyle(submenu, 'left', `${left}px`);\n this.renderer.setStyle(submenu, 'top', `${top}px`);\n this.renderer.setStyle(submenu, 'position', 'fixed'); // Fixed position relative to the viewport\n }\n\n @HostListener('click', ['$event'])\n private handleClick(e: MouseEvent) {\n e.stopPropagation();\n if (this.disabled()) return;\n //\n const event = {\n sender: this,\n nativeEvent: e,\n canceled: false,\n item: {\n name: this.name(),\n text: this.getText(),\n data: this.data(),\n },\n } as AXMenuItemClickEvent;\n //\n this.onClick.emit(event);\n this.root.onItemClick.emit({ ...event, ...{ sender: this.root as any } });\n //\n if (this.hasSubItems() && !event.canceled) {\n this.open();\n } else if (!event.canceled) {\n this.service.closeAll$.next();\n this.service.closeAllContextMenu$.next({ sender: this.root });\n }\n }\n\n @HostListener('mouseenter', ['$event'])\n private handleMouseEnter(event: MouseEvent) {\n event.stopPropagation();\n // Cancel the close delay if the mouse re-enters the element\n if (this.mouseLeaveTimeout) {\n clearTimeout(this.mouseLeaveTimeout);\n this.mouseLeaveTimeout = null; // Reset the timeout\n }\n if (!this.isFirstLevel() || this.root.openOn() == 'hover') {\n this.open();\n }\n }\n\n private mouseLeaveTimeout: any;\n\n @HostListener('mouseleave', ['$event'])\n private handleMouseLeave(event: MouseEvent) {\n event.stopPropagation();\n\n if (this.hasSubItems() && this.root.closeOn() === 'leave') {\n // Clear any previous timeout to avoid multiple triggers\n if (this.mouseLeaveTimeout) {\n clearTimeout(this.mouseLeaveTimeout);\n }\n\n // Set a delay before closing the submenu\n this.mouseLeaveTimeout = setTimeout(() => {\n this.close();\n }, 500); // Adjust the delay (500ms in this case) as per your requirement\n }\n }\n\n @HostListener('window:scroll', ['$event'])\n @HostListener('window:resize', ['$event'])\n private onWindowEvent() {\n this.service.closeAll$.next(); // Close all menus on scroll or resize\n }\n\n /**\n * Close all menus if clicking outside the root menu and all sub-items.\n */\n @HostListener('document:click', ['$event'])\n private onClickOutside(event: MouseEvent) {\n const hostElement = this.root.nativeElement;\n if (!hostElement.contains(event.target as Node)) {\n this.service.closeAll$.next(); // Close all menus if click is outside the root and sub-items\n }\n }\n\n ngOnDestroy() {\n this.removeScrollEvents();\n }\n\n private bindScrollEvents() {\n this.scrollableParents = AXHtmlUtil.getScrollableParents(this.nativeElement);\n\n this.scrollableParents.forEach((parent) => {\n parent.addEventListener('scroll', this.onContainerScroll.bind(this));\n });\n }\n\n // Remove scroll event listeners\n private removeScrollEvents() {\n this.scrollableParents.forEach((parent) => {\n parent.removeEventListener('scroll', this.onContainerScroll.bind(this));\n });\n }\n\n /**\n * Handler for scroll events (window or scrollable parent containers)\n */\n private onContainerScroll() {\n this.service.closeAll$.next(); // Close all menus on scroll\n }\n\n /** @ignore */\n @HostBinding('class')\n get __hostClass(): string[] {\n const list: string[] = ['ax-el-interactive', 'ax-action-item'];\n if (this.disabled()) {\n list.push('ax-state-disabled');\n }\n if (this.color()) {\n list.push(`ax-el-${this.color()}-blank`);\n }\n\n return list;\n }\n}\n","<div class=\"ax-action-item-prefix\">\n <ng-content select=\"ax-prefix\"></ng-content>\n <ng-content select=\"ax-text\"></ng-content>\n</div>\n<div class=\"ax-action-item-suffix\">\n <ng-content select=\"ax-suffix\"></ng-content>\n @if (hasSubItems() && (root.hasArrow() || !isRoot())) {\n <i class=\"ax-icon ax-icon-solid {{ arrowIcon() }} ax-menu-item-child-icon\"></i>\n }\n</div>\n<div class=\"ax-menu-items ax-action-list ax-action-list-vertical\" [class.ax-state-open]=\"isOpen()\">\n <ng-content select=\"ax-menu-item,ax-title,ax-divider,ng-container\"></ng-content>\n</div>\n","import { AXOrientation, NXComponent, NXEvent } from '@acorex/components/common';\nimport {\n afterNextRender,\n ChangeDetectionStrategy,\n Component,\n HostBinding,\n HostListener,\n inject,\n input,\n output,\n Renderer2,\n signal,\n ViewEncapsulation,\n} from '@angular/core';\nimport { AXMenuCloseTrigger, AXMenuItem, AXMenuItemClickBaseEvent, AXMenuOpenTrigger, AXRootMenu } from './menu.types';\nimport { AXMenuService } from './menu.service';\nimport { AXHtmlUtil, AXPoint } from '@acorex/core/utils';\nimport { cloneDeep } from 'lodash-es';\nimport { isBrowser } from '@acorex/core/platform';\n\n\nexport class AXContextMenuOpeningEvent extends NXEvent<AXContextMenuComponent> {\n items: AXMenuItem[];\n canceled = false;\n targetElement: HTMLElement\n\n}\nexport type AXContextMenuItemsClickEvent = AXMenuItemClickBaseEvent<AXContextMenuComponent>\n\n/**\n * Represents a menu component that displays context menu.\n * @category Components\n */\n@Component({\n selector: 'ax-context-menu',\n templateUrl: './menu.component.html',\n styleUrls: ['./menu.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n providers: [\n AXMenuService,\n {\n provide: AXRootMenu,\n useExisting: AXContextMenuComponent\n }\n ]\n})\nexport class AXContextMenuComponent extends NXComponent {\n\n // Inputs and Outputs\n\n orientation = input<AXOrientation>('vertical');\n openOn = input<AXMenuOpenTrigger>('hover');\n closeOn = input<AXMenuCloseTrigger>('click');\n orginalItems = input<AXMenuItem[]>([], { alias: \"items\" });\n target = input<HTMLElement | HTMLElement[] | string>();\n\n onItemClick = output<AXContextMenuItemsClickEvent>();\n onOpening = output<AXContextMenuOpeningEvent>();\n\n // Injected Services\n\n private service = inject(AXMenuService);\n private renderer = inject(Renderer2)\n\n // Constructor (Dependency Injection)\n\n /** @ignore */\n constructor() {\n super();\n //\n afterNextRender(() => {\n this.bindContextEvent();\n });\n\n this.service.closeAllContextMenu$.subscribe(() => {\n this.service.closeAll$.next();\n this.close();\n });\n\n this.service.openContextMenu$.subscribe((e) => {\n if (e.sender as any == this) {\n this.internalShowAt(e.point);\n }\n });\n }\n\n\n\n // Lifecycle Hooks\n\n ngOnDestroy() {\n if (isBrowser()) {\n this.removeContextEvent();\n }\n }\n\n public refresh(){\n this.bindContextEvent()\n }\n\n // Public Methods\n\n public showAt(point: AXPoint) {\n const sender = this as any as AXRootMenu;\n this.service.closeAllContextMenu$.next({ sender });\n this.service.openContextMenu$.next({ sender, point });\n }\n\n public close() {\n this.nativeElement.classList.remove('ax-state-open');\n this.removeBackdrop();\n }\n\n // Private Properties\n\n private backdropElement!: HTMLElement;\n\n protected items = signal<AXMenuItem[]>([]);\n\n // Private Methods (Internal Logic)\n\n /** @ignore */\n private getTargetElements(): HTMLElement[] {\n const elements: HTMLElement[] = typeof this.target() == 'string' ?\n Array.from(document.querySelectorAll<HTMLElement>(this.target() as string)) :\n Array.isArray(this.target()) ?\n this.target() as HTMLElement[] :\n [this.target() as HTMLElement]\n\n return elements;\n }\n\n /** @ignore */\n private bindContextEvent() {\n this.getTargetElements().forEach((e) => {\n e.addEventListener('contextmenu', this.handleContextMenu.bind(this));\n })\n }\n\n /** @ignore */\n private removeContextEvent() {\n this.getTargetElements().forEach((e) => {\n e.removeEventListener('contextmenu', this.handleContextMenu.bind(this));\n })\n }\n\n /** @ignore */\n private handleContextMenu(e: MouseEvent) {\n e.preventDefault();\n e.stopPropagation();\n //\n const elementsUnderMouse = document.elementsFromPoint(e.x, e.y) as HTMLElement[];\n const targetElements = this.getTargetElements();\n const targetElement = elementsUnderMouse.find(target => targetElements.includes(target))\n //\n const event = {\n sender: this,\n canceled: false,\n targetElement: targetElement,\n items: cloneDeep(this.orginalItems()),\n } as AXContextMenuOpeningEvent;\n this.onOpening.emit(event);\n this.items.set(event.items);\n //\n if (!event.canceled) {\n this.showAt({ x: e.clientX, y: e.clientY });\n }\n }\n\n /** @ignore */\n private internalShowAt(point: AXPoint) {\n const elementRef = this.nativeElement;\n elementRef.classList.add('ax-state-open');\n const itemRect = elementRef.getBoundingClientRect();\n const windowWidth = window.innerWidth;\n const windowHeight = window.innerHeight;\n\n // Detect RTL (Right-To-Left) mode\n const isRtl = AXHtmlUtil.isRtl(elementRef);\n\n let left: number;\n if (isRtl) {\n left = point.x - itemRect.width;\n if (left < 0) {\n left = point.x;\n }\n } else {\n left = point.x;\n if (left + itemRect.width > windowWidth) {\n left = point.x - itemRect.width;\n }\n }\n\n const bottom = point.y + itemRect.height;\n let top: number;\n\n if (bottom > windowHeight) {\n top = point.y - itemRect.height;\n if (top < 0) {\n top = 0;\n }\n } else {\n top = point.y;\n }\n\n this.renderer.setStyle(elementRef, 'left', `${left}px`);\n this.renderer.setStyle(elementRef, 'top', `${top}px`);\n this.renderer.setStyle(elementRef, 'position', 'fixed');\n\n this.createBackdrop();\n }\n\n /** @ignore */\n private createBackdrop() {\n this.backdropElement = this.renderer.createElement('div');\n this.renderer.setStyle(this.backdropElement, 'position', 'fixed');\n this.renderer.setStyle(this.backdropElement, 'top', '0');\n this.renderer.setStyle(this.backdropElement, 'left', '0');\n this.renderer.setStyle(this.backdropElement, 'width', '100%');\n this.renderer.setStyle(this.backdropElement, 'height', '100%');\n this.renderer.setStyle(this.backdropElement, 'z-index', '999'); // Ensure it's below the context menu\n this.renderer.setStyle(this.backdropElement, 'background', 'transparent');\n\n const l1 = this.renderer.listen(this.backdropElement, 'click', () => {\n this.close();\n l1();\n });\n\n const l2 = this.renderer.listen(this.backdropElement, 'wheel', () => {\n this.close();\n l2();\n });\n\n const l3 = this.renderer.listen(this.backdropElement, 'contextmenu', (e: MouseEvent) => {\n this.close();\n // Get all elements under the mouse pointer\n const elementsUnderMouse = document.elementsFromPoint(e.x, e.y) as HTMLElement[];\n const targetElements = this.getTargetElements();\n if (targetElements.some(target => elementsUnderMouse.includes(target))) {\n e.preventDefault();\n setTimeout(() => {\n //this.internalShowAt({ x: e.x, y: e.y });\n this.handleContextMenu(e);\n });\n }\n l3();\n });\n\n document.body.appendChild(this.backdropElement);\n }\n\n /** @ignore */\n private removeBackdrop() {\n if (this.backdropElement) {\n if (this.backdropElement.parentNode) {\n this.backdropElement.parentNode.removeChild(this.backdropElement);\n }\n this.backdropElement = null;\n }\n }\n\n // Host Listeners (UI Interaction Handling)\n\n /** @ignore */\n @HostListener('window:scroll', ['$event'])\n @HostListener('window:resize', ['$event'])\n private onWindowEvent() {\n const sender = this as any as AXRootMenu;\n this.service.closeAllContextMenu$.next({ sender: sender }); // Close all menus on scroll or resize\n }\n\n /** @ignore */\n @HostBinding('class')\n get __hostClass(): any {\n return ['ax-menu-container', `ax-orientation-${this.orientation()}`, 'ax-action-list', 'ax-action-list-vertical'];\n }\n}\n","<ng-content select=\"ax-menu-item,ax-divider,ax-title,ng-container\"></ng-content>\n\n<ng-container\n *ngFor=\"let node of items()\"\n [ngTemplateOutlet]=\"Recursion\"\n [ngTemplateOutletContext]=\"{ $implicit: node }\"\n>\n</ng-container>\n<ng-template #Recursion let-item>\n @if (item.group?.title) {\n <ax-title>{{ item.group?.title }}</ax-title>\n }\n <ax-menu-item [name]=\"item.name\" [data]=\"item.data\" [disabled]=\"item.disabled\" [color]=\"item.color\">\n <ax-prefix>\n @if (item.icon) {\n <ax-icon [icon]=\"item.icon\"> </ax-icon>\n }\n </ax-prefix>\n @if (item.text) {\n <ax-text>{{ item.text }}</ax-text>\n }\n @if (item.suffix) {\n <ax-suffix>\n <ax-text>{{ item.suffix.text }}</ax-text>\n </ax-suffix>\n }\n <ng-container\n *ngFor=\"let child of item.items\"\n [ngTemplateOutlet]=\"Recursion\"\n [ngTemplateOutletContext]=\"{ $implicit: child }\"\n ></ng-container>\n </ax-menu-item>\n @if (item.break) {\n <ax-divider></ax-divider>\n }\n</ng-template>\n","import { AXOrientation, NXComponent } from '@acorex/components/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n HostBinding,\n inject,\n input,\n output,\n ViewEncapsulation,\n} from '@angular/core';\nimport { AXMenuService } from './menu.service';\nimport {\n AXMenuCloseTrigger,\n AXMenuItem,\n AXMenuItemClickBaseEvent,\n AXMenuOpenTrigger,\n AXRootMenu,\n} from './menu.types';\n\nexport type AXMenuItemsClickEvent = AXMenuItemClickBaseEvent<AXMenuComponent>;\n\n/**\n * Represents a menu component that displays menu items.\n * @category Components\n */\n@Component({\n selector: 'ax-menu',\n templateUrl: './menu.component.html',\n styleUrls: ['./menu.component.scss'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [\n AXMenuService,\n {\n provide: AXRootMenu,\n useExisting: AXMenuComponent,\n },\n ],\n})\nexport class AXMenuComponent extends NXComponent {\n orientation = input<AXOrientation>('horizontal');\n\n openOn = input<AXMenuOpenTrigger>('hover');\n\n closeOn = input<AXMenuCloseTrigger>('leave');\n\n service = inject(AXMenuService);\n\n onItemClick = output<AXMenuItemsClickEvent>();\n\n items = input<AXMenuItem[]>([]);\n\n hasArrow = input<boolean>(true);\n\n /** @ignore */\n @HostBinding('class')\n get __hostClass(): string[] {\n return [\n 'ax-root-menu',\n 'ax-action-list',\n `ax-action-list-${this.orientation()}`,\n `${!this.hasArrow() ? 'ax-hide-arrow' : ''}`,\n ];\n }\n\n public close() {\n this.service.closeAll$.next();\n }\n}\n","import { AXDecoratorModule } from '@acorex/components/decorators';\nimport { AXLoadingModule } from '@acorex/components/loading';\nimport { AXPopoverModule } from '@acorex/components/popover';\nimport { AXTranslationModule } from '@acorex/core/translation';\nimport { OverlayModule } from '@angular/cdk/overlay';\nimport { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\n\nimport { AXContextMenuComponent } from './context-menu.component';\nimport { AXMenuItemComponent } from './menu-item.component';\nimport { AXMenuComponent } from './menu.component';\n\nconst COMPONENT = [AXMenuItemComponent, AXMenuComponent, AXContextMenuComponent];\nconst MODULES = [AXDecoratorModule, AXLoadingModule, AXTranslationModule, OverlayModule, AXPopoverModule];\n\n@NgModule({\n declarations: [...COMPONENT],\n imports: [CommonModule, ...MODULES],\n exports: [...COMPONENT],\n providers: [],\n})\nexport class AXMenuModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i3.AXMenuItemComponent"],"mappings":";;;;;;;;;;;;;;;;MAMsB,UAAU,CAAA;AAO/B;MAEqB,uBAAuB,CAAA;AAAG;MAE1B,UAAU,CAAA;AAgB/B;AAEK,MAAO,wBAA8D,SAAQ,YAAe,CAAA;AAAlG,IAAA,WAAA,GAAA;;QAME,IAAQ,CAAA,QAAA,GAAG,KAAK;;AACjB;;MCpCY,aAAa,CAAA;AAD1B,IAAA,WAAA,GAAA;AAES,QAAA,IAAA,CAAA,SAAS,GAAkB,IAAI,OAAO,EAAE;AACxC,QAAA,IAAA,CAAA,KAAK,GAAqC,IAAI,OAAO,EAAE;AACvD,QAAA,IAAA,CAAA,MAAM,GAAqC,IAAI,OAAO,EAAE;AACxD,QAAA,IAAA,CAAA,YAAY,GAAG,IAAI,OAAO,EAA2B;AAErD,QAAA,IAAA,CAAA,gBAAgB,GAAG,IAAI,OAAO,EAA0C;AACxE,QAAA,IAAA,CAAA,oBAAoB,GAAG,IAAI,OAAO,EAA0B;AACpE;8GARY,aAAa,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,C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,SAAS,CAAC;AACvB,oBAAA,SAAS,EAAE,EAAE;AACd,iBAAA;;;ACpBD;;AAEG;;;;"}
1
+ {"version":3,"file":"acorex-components-menu.mjs","sources":["../../../../libs/components/menu/src/lib/menu.types.ts","../../../../libs/components/menu/src/lib/menu.service.ts","../../../../libs/components/menu/src/lib/menu-item.component.ts","../../../../libs/components/menu/src/lib/menu-item.component.html","../../../../libs/components/menu/src/lib/context-menu.component.ts","../../../../libs/components/menu/src/lib/menu.component.html","../../../../libs/components/menu/src/lib/menu.component.ts","../../../../libs/components/menu/src/lib/menu.module.ts","../../../../libs/components/menu/src/acorex-components-menu.ts"],"sourcesContent":["import { AXOrientation, AXStyleColorType, NXClickEvent, NXComponent } from '@acorex/components/common';\nimport { OutputEmitterRef, WritableSignal } from '@angular/core';\n\nexport type AXMenuOpenTrigger = 'click' | 'hover';\nexport type AXMenuCloseTrigger = 'click' | 'leave';\n\nexport abstract class AXRootMenu {\n orientation: WritableSignal<AXOrientation>;\n openOn: WritableSignal<AXMenuOpenTrigger>;\n closeOn: WritableSignal<AXMenuCloseTrigger>;\n onItemClick: OutputEmitterRef<AXMenuItemClickBaseEvent>;\n nativeElement: HTMLDivElement;\n hasArrow: WritableSignal<boolean>;\n}\n\nexport abstract class AXMenuItemComponentBase {}\n\nexport abstract class AXMenuItem {\n color?: AXStyleColorType;\n name?: string;\n text: string;\n data?: any;\n icon?: string;\n disabled?: boolean;\n items?: AXMenuItem[];\n suffix?: {\n text: string;\n };\n break?: boolean;\n group?: {\n name?: string;\n title?: string;\n };\n}\n\nexport class AXMenuItemClickBaseEvent<T extends NXComponent = NXComponent> extends NXClickEvent<T> {\n item: {\n name?: string;\n text: string;\n data?: any;\n };\n canceled = false;\n}\n","import { Injectable } from '@angular/core';\nimport { Subject } from 'rxjs';\nimport { AXMenuItemComponentBase, AXRootMenu } from './menu.types';\nimport { AXPoint } from '@acorex/core/utils';\n\n@Injectable()\nexport class AXMenuService {\n public closeAll$: Subject<void> = new Subject();\n public open$: Subject<AXMenuItemComponentBase> = new Subject();\n public close$: Subject<AXMenuItemComponentBase> = new Subject();\n public closeExcept$ = new Subject<AXMenuItemComponentBase>();\n\n public openContextMenu$ = new Subject<{ sender: AXRootMenu, point: AXPoint }>();\n public closeAllContextMenu$ = new Subject<{ sender: AXRootMenu }>();\n}\n","import { AXStyleColorType, NXComponent } from '@acorex/components/common';\nimport { AXHtmlUtil, AXUnsubscriber } from '@acorex/core/utils';\nimport {\n afterNextRender,\n ChangeDetectionStrategy,\n Component,\n computed,\n HostBinding,\n HostListener,\n inject,\n input,\n output,\n Renderer2,\n signal,\n ViewEncapsulation,\n} from '@angular/core';\nimport { AXMenuService } from './menu.service';\nimport { AXMenuItemClickBaseEvent, AXMenuItemComponentBase, AXRootMenu } from './menu.types';\n\nexport type AXMenuItemClickEvent = AXMenuItemClickBaseEvent<AXMenuItemComponent>;\n\n/**\n * Represents a menu item component used within an `ax-menu`.\n * @category Components\n */\n@Component({\n selector: 'ax-menu-item',\n templateUrl: './menu-item.component.html',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [\n {\n provide: AXMenuItemComponentBase,\n useExisting: AXMenuItemComponent,\n },\n AXUnsubscriber,\n ],\n})\nexport class AXMenuItemComponent extends NXComponent {\n protected isOpen = signal(false);\n protected hasSubItems = signal(false);\n protected isFirstLevel = signal(false);\n private mutationObserver!: MutationObserver;\n\n protected root = inject(AXRootMenu);\n protected parent?: AXMenuItemComponent | null;\n protected isRoot = () => this.parent == null;\n\n private service = inject(AXMenuService);\n private scrollableParents: HTMLElement[] = [];\n\n private unsuscriber = inject(AXUnsubscriber);\n private renderer = inject(Renderer2);\n\n protected arrowIcon = computed(() => {\n const isRtl = AXHtmlUtil.isRtl(this.nativeElement);\n return this.root.orientation() == 'horizontal' && this.isFirstLevel()\n ? 'ax-icon-chevron-down'\n : isRtl\n ? 'ax-icon-chevron-left'\n : 'ax-icon-chevron-right';\n });\n\n onClick = output<AXMenuItemClickEvent>();\n\n name = input<string>();\n data = input<any>();\n disabled = input<boolean>();\n color = input<AXStyleColorType>();\n\n constructor() {\n super();\n //\n afterNextRender(() => {\n this.detectSubItems();\n this.observeMutations();\n this.bindScrollEvents();\n });\n //\n this.service.closeAll$.pipe(this.unsuscriber.takeUntilDestroy).subscribe(() => this.close());\n\n this.service.open$.pipe(this.unsuscriber.takeUntilDestroy).subscribe((item) => {\n if ((this as any) === item) {\n this.isOpen.set(true);\n this.calculatePosition();\n }\n });\n //\n this.service.close$.pipe(this.unsuscriber.takeUntilDestroy).subscribe((item) => {\n if ((this as any) == item) {\n this.isOpen.set(false);\n }\n });\n //\n this.service.closeExcept$.pipe(this.unsuscriber.takeUntilDestroy).subscribe((item) => {\n this.closeExcept(item as AXMenuItemComponent);\n });\n }\n\n private closeExcept(item: AXMenuItemComponent) {\n const list: AXMenuItemComponent[] = [item];\n //\n let parent = item.parent;\n while (parent != null) {\n list.push(parent);\n parent = parent.parent;\n }\n //\n if (!list.includes(this)) {\n this.close();\n }\n }\n\n private observeMutations() {\n this.mutationObserver = new MutationObserver(() => {\n this.detectSubItems();\n });\n\n // Start observing changes in child elements\n this.mutationObserver.observe(this.nativeElement, {\n childList: true,\n subtree: true,\n });\n }\n\n private getText(): string {\n return this.nativeElement.querySelector<HTMLDivElement>('ax-text')?.innerText;\n }\n\n /**\n * Manually detect all `ax-menu-item` elements and check if this menu item has sub-items.\n */\n private detectSubItems() {\n //\n const parentEl = this.nativeElement.parentElement?.parentElement;\n this.parent =\n parentEl?.tagName == 'AX-MENU-ITEM' ? (parentEl?.['__axContext__'] as AXMenuItemComponent) : null;\n //\n const tag = this.nativeElement.parentElement?.tagName;\n this.isFirstLevel.set(tag == 'AX-MENU' || tag == 'AX-CONTEXT-MENU');\n const subItems = this.nativeElement.querySelectorAll('ax-menu-item');\n if (subItems.length > 0) {\n this.hasSubItems.set(true);\n } else {\n this.hasSubItems.set(false);\n }\n }\n\n open() {\n this.service.closeExcept$.next(this);\n if (!this.disabled() && this.hasSubItems()) {\n this.service.open$.next(this);\n }\n }\n\n close() {\n this.service.close$.next(this);\n }\n\n /**\n * Calculate the position of the submenu to avoid it going out of the viewport.\n */\n private calculatePosition() {\n const submenu = this.nativeElement.querySelector('.ax-menu-items');\n if (!submenu) return;\n\n const submenuRect = submenu.getBoundingClientRect();\n const itemRect = this.nativeElement.getBoundingClientRect();\n const windowWidth = window.innerWidth;\n const windowHeight = window.innerHeight;\n\n const isRtl = AXHtmlUtil.isRtl(this.nativeElement);\n\n let top: number | null = null;\n let left: number | null = null;\n\n // For first-level menu items\n if (this.isFirstLevel() && this.root.orientation() === 'horizontal') {\n top =\n itemRect.bottom + submenuRect.height > windowHeight\n ? itemRect.top - submenuRect.height // Open upwards\n : itemRect.bottom; // Open downwards\n\n if (isRtl) {\n // RTL: Align to the right of the parent item\n left =\n itemRect.right - submenuRect.width < 0\n ? itemRect.left // Align to the left if not enough space on the right\n : itemRect.right - submenuRect.width; // Open to the left in RTL\n } else {\n // LTR: Align to the left of the parent item\n left =\n itemRect.left + submenuRect.width > windowWidth\n ? itemRect.right - submenuRect.width // Align to the right edge in LTR\n : itemRect.left; // Open to the left\n }\n } else {\n // For nested submenus\n if (isRtl) {\n // RTL: Nested submenu opens to the left\n left =\n itemRect.left - submenuRect.width < 0\n ? itemRect.right // Align to the right if not enough space on the left\n : itemRect.left - submenuRect.width; // Open to the left in RTL\n } else {\n // LTR: Nested submenu opens to the right\n left =\n itemRect.right + submenuRect.width > windowWidth\n ? itemRect.left - submenuRect.width // Open to the left if not enough space\n : itemRect.right; // Open to the right in LTR\n }\n\n // Adjust top position (align vertically with parent)\n top =\n itemRect.top + submenuRect.height > windowHeight\n ? itemRect.top - (itemRect.bottom + submenuRect.height - windowHeight) // Adjust upwards\n : itemRect.top; // Align with the parent item\n }\n\n // Apply calculated styles for RTL/LTR\n this.renderer.setStyle(submenu, 'left', `${left}px`);\n this.renderer.setStyle(submenu, 'top', `${top}px`);\n this.renderer.setStyle(submenu, 'position', 'fixed'); // Fixed position relative to the viewport\n }\n\n @HostListener('click', ['$event'])\n private handleClick(e: MouseEvent) {\n e.stopPropagation();\n if (this.disabled()) return;\n //\n const event = {\n sender: this,\n nativeEvent: e,\n canceled: false,\n item: {\n name: this.name(),\n text: this.getText(),\n data: this.data(),\n },\n } as AXMenuItemClickEvent;\n //\n this.onClick.emit(event);\n this.root.onItemClick.emit({ ...event, ...{ sender: this.root as any } });\n //\n if (this.hasSubItems() && !event.canceled) {\n this.open();\n } else if (!event.canceled) {\n this.service.closeAll$.next();\n this.service.closeAllContextMenu$.next({ sender: this.root });\n }\n }\n\n @HostListener('mouseenter', ['$event'])\n private handleMouseEnter(event: MouseEvent) {\n event.stopPropagation();\n // Cancel the close delay if the mouse re-enters the element\n if (this.mouseLeaveTimeout) {\n clearTimeout(this.mouseLeaveTimeout);\n this.mouseLeaveTimeout = null; // Reset the timeout\n }\n if (!this.isFirstLevel() || this.root.openOn() == 'hover') {\n this.open();\n }\n }\n\n private mouseLeaveTimeout: any;\n\n @HostListener('mouseleave', ['$event'])\n private handleMouseLeave(event: MouseEvent) {\n event.stopPropagation();\n\n if (this.hasSubItems() && this.root.closeOn() === 'leave') {\n // Clear any previous timeout to avoid multiple triggers\n if (this.mouseLeaveTimeout) {\n clearTimeout(this.mouseLeaveTimeout);\n }\n\n // Set a delay before closing the submenu\n this.mouseLeaveTimeout = setTimeout(() => {\n this.close();\n }, 500); // Adjust the delay (500ms in this case) as per your requirement\n }\n }\n\n @HostListener('window:scroll', ['$event'])\n @HostListener('window:resize', ['$event'])\n private onWindowEvent() {\n this.service.closeAll$.next(); // Close all menus on scroll or resize\n }\n\n /**\n * Close all menus if clicking outside the root menu and all sub-items.\n */\n @HostListener('document:click', ['$event'])\n private onClickOutside(event: MouseEvent) {\n const hostElement = this.root.nativeElement;\n if (!hostElement.contains(event.target as Node)) {\n this.service.closeAll$.next(); // Close all menus if click is outside the root and sub-items\n }\n }\n\n ngOnDestroy() {\n this.removeScrollEvents();\n }\n\n private bindScrollEvents() {\n this.scrollableParents = AXHtmlUtil.getScrollableParents(this.nativeElement);\n\n this.scrollableParents.forEach((parent) => {\n parent.addEventListener('scroll', this.onContainerScroll.bind(this));\n });\n }\n\n // Remove scroll event listeners\n private removeScrollEvents() {\n this.scrollableParents.forEach((parent) => {\n parent.removeEventListener('scroll', this.onContainerScroll.bind(this));\n });\n }\n\n /**\n * Handler for scroll events (window or scrollable parent containers)\n */\n private onContainerScroll() {\n this.service.closeAll$.next(); // Close all menus on scroll\n }\n\n /** @ignore */\n @HostBinding('class')\n get __hostClass(): string[] {\n const list: string[] = ['ax-el-interactive', 'ax-action-item'];\n if (this.disabled()) {\n list.push('ax-state-disabled');\n }\n if (this.color()) {\n list.push(`ax-el-${this.color()}-blank`);\n }\n\n return list;\n }\n}\n","<div class=\"ax-action-item-prefix\">\n <ng-content select=\"ax-prefix\"></ng-content>\n <ng-content select=\"ax-text\"></ng-content>\n</div>\n<div class=\"ax-action-item-suffix\">\n <ng-content select=\"ax-suffix\"></ng-content>\n @if (hasSubItems() && (root.hasArrow() || !isRoot())) {\n <i class=\"ax-icon ax-icon-solid {{ arrowIcon() }} ax-menu-item-child-icon\"></i>\n }\n</div>\n<div class=\"ax-menu-items ax-action-list ax-action-list-vertical\" [class.ax-state-open]=\"isOpen()\">\n <ng-content select=\"ax-menu-item,ax-title,ax-divider,ng-container\"></ng-content>\n</div>\n","import { AXOrientation, NXComponent, NXEvent } from '@acorex/components/common';\nimport { isBrowser } from '@acorex/core/platform';\nimport { AXHtmlUtil, AXPoint } from '@acorex/core/utils';\nimport { DOCUMENT } from '@angular/common';\nimport {\n afterNextRender,\n ChangeDetectionStrategy,\n Component,\n HostBinding,\n HostListener,\n inject,\n input,\n output,\n Renderer2,\n signal,\n ViewEncapsulation,\n} from '@angular/core';\nimport { cloneDeep } from 'lodash-es';\nimport { AXMenuService } from './menu.service';\nimport {\n AXMenuCloseTrigger,\n AXMenuItem,\n AXMenuItemClickBaseEvent,\n AXMenuOpenTrigger,\n AXRootMenu,\n} from './menu.types';\n\nexport class AXContextMenuOpeningEvent extends NXEvent<AXContextMenuComponent> {\n items: AXMenuItem[];\n canceled = false;\n targetElement: HTMLElement;\n}\nexport type AXContextMenuItemsClickEvent = AXMenuItemClickBaseEvent<AXContextMenuComponent>;\n\n/**\n * Represents a menu component that displays context menu.\n * @category Components\n */\n@Component({\n selector: 'ax-context-menu',\n templateUrl: './menu.component.html',\n styleUrls: ['./menu.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n providers: [\n AXMenuService,\n {\n provide: AXRootMenu,\n useExisting: AXContextMenuComponent,\n },\n ],\n})\nexport class AXContextMenuComponent extends NXComponent {\n // Inputs and Outputs\n\n orientation = input<AXOrientation>('vertical');\n openOn = input<AXMenuOpenTrigger>('hover');\n closeOn = input<AXMenuCloseTrigger>('click');\n orginalItems = input<AXMenuItem[]>([], { alias: 'items' });\n target = input<HTMLElement | HTMLElement[] | string>();\n\n onItemClick = output<AXContextMenuItemsClickEvent>();\n onOpening = output<AXContextMenuOpeningEvent>();\n\n // Injected Services\n\n private service = inject(AXMenuService);\n private renderer = inject(Renderer2);\n private document = inject(DOCUMENT);\n\n // Constructor (Dependency Injection)\n\n /** @ignore */\n constructor() {\n super();\n //\n afterNextRender(() => {\n this.bindContextEvent();\n });\n\n this.service.closeAllContextMenu$.subscribe(() => {\n this.service.closeAll$.next();\n this.close();\n });\n\n this.service.openContextMenu$.subscribe((e) => {\n if ((e.sender as any) == this) {\n this.internalShowAt(e.point);\n }\n });\n }\n\n // Lifecycle Hooks\n\n ngOnDestroy() {\n if (isBrowser()) {\n this.removeContextEvent();\n }\n }\n\n public refresh() {\n this.bindContextEvent();\n }\n\n // Public Methods\n\n public showAt(point: AXPoint) {\n const sender = this as any as AXRootMenu;\n this.service.closeAllContextMenu$.next({ sender });\n this.service.openContextMenu$.next({ sender, point });\n }\n\n public close() {\n this.nativeElement.classList.remove('ax-state-open');\n this.removeBackdrop();\n }\n\n // Private Properties\n\n private backdropElement!: HTMLElement;\n\n protected items = signal<AXMenuItem[]>([]);\n\n // Private Methods (Internal Logic)\n\n /** @ignore */\n private getTargetElements(): HTMLElement[] {\n const elements: HTMLElement[] =\n typeof this.target() == 'string'\n ? Array.from(this.document.querySelectorAll<HTMLElement>(this.target() as string))\n : Array.isArray(this.target())\n ? (this.target() as HTMLElement[])\n : [this.target() as HTMLElement];\n\n return elements;\n }\n\n /** @ignore */\n private bindContextEvent() {\n this.getTargetElements().forEach((e) => {\n e.addEventListener('contextmenu', this.handleContextMenu.bind(this));\n });\n }\n\n /** @ignore */\n private removeContextEvent() {\n this.getTargetElements().forEach((e) => {\n e.removeEventListener('contextmenu', this.handleContextMenu.bind(this));\n });\n }\n\n /** @ignore */\n private handleContextMenu(e: MouseEvent) {\n e.preventDefault();\n e.stopPropagation();\n //\n const elementsUnderMouse = this.document.elementsFromPoint(e.x, e.y) as HTMLElement[];\n const targetElements = this.getTargetElements();\n const targetElement = elementsUnderMouse.find((target) => targetElements.includes(target));\n //\n const event = {\n sender: this,\n canceled: false,\n targetElement: targetElement,\n items: cloneDeep(this.orginalItems()),\n } as AXContextMenuOpeningEvent;\n this.onOpening.emit(event);\n this.items.set(event.items);\n //\n if (!event.canceled) {\n this.showAt({ x: e.clientX, y: e.clientY });\n }\n }\n\n /** @ignore */\n private internalShowAt(point: AXPoint) {\n const elementRef = this.nativeElement;\n elementRef.classList.add('ax-state-open');\n const itemRect = elementRef.getBoundingClientRect();\n const windowWidth = window.innerWidth;\n const windowHeight = window.innerHeight;\n\n // Detect RTL (Right-To-Left) mode\n const isRtl = AXHtmlUtil.isRtl(elementRef);\n\n let left: number;\n if (isRtl) {\n left = point.x - itemRect.width;\n if (left < 0) {\n left = point.x;\n }\n } else {\n left = point.x;\n if (left + itemRect.width > windowWidth) {\n left = point.x - itemRect.width;\n }\n }\n\n const bottom = point.y + itemRect.height;\n let top: number;\n\n if (bottom > windowHeight) {\n top = point.y - itemRect.height;\n if (top < 0) {\n top = 0;\n }\n } else {\n top = point.y;\n }\n\n this.renderer.setStyle(elementRef, 'left', `${left}px`);\n this.renderer.setStyle(elementRef, 'top', `${top}px`);\n this.renderer.setStyle(elementRef, 'position', 'fixed');\n\n this.createBackdrop();\n }\n\n /** @ignore */\n private createBackdrop() {\n this.backdropElement = this.renderer.createElement('div');\n this.renderer.setStyle(this.backdropElement, 'position', 'fixed');\n this.renderer.setStyle(this.backdropElement, 'top', '0');\n this.renderer.setStyle(this.backdropElement, 'left', '0');\n this.renderer.setStyle(this.backdropElement, 'width', '100%');\n this.renderer.setStyle(this.backdropElement, 'height', '100%');\n this.renderer.setStyle(this.backdropElement, 'z-index', '999'); // Ensure it's below the context menu\n this.renderer.setStyle(this.backdropElement, 'background', 'transparent');\n\n const l1 = this.renderer.listen(this.backdropElement, 'click', () => {\n this.close();\n l1();\n });\n\n const l2 = this.renderer.listen(this.backdropElement, 'wheel', () => {\n this.close();\n l2();\n });\n\n const l3 = this.renderer.listen(this.backdropElement, 'contextmenu', (e: MouseEvent) => {\n this.close();\n // Get all elements under the mouse pointer\n const elementsUnderMouse = this.document.elementsFromPoint(e.x, e.y) as HTMLElement[];\n const targetElements = this.getTargetElements();\n if (targetElements.some((target) => elementsUnderMouse.includes(target))) {\n e.preventDefault();\n setTimeout(() => {\n //this.internalShowAt({ x: e.x, y: e.y });\n this.handleContextMenu(e);\n });\n }\n l3();\n });\n\n this.document.body.appendChild(this.backdropElement);\n }\n\n /** @ignore */\n private removeBackdrop() {\n if (this.backdropElement) {\n if (this.backdropElement.parentNode) {\n this.backdropElement.parentNode.removeChild(this.backdropElement);\n }\n this.backdropElement = null;\n }\n }\n\n // Host Listeners (UI Interaction Handling)\n\n /** @ignore */\n @HostListener('window:scroll', ['$event'])\n @HostListener('window:resize', ['$event'])\n private onWindowEvent() {\n const sender = this as any as AXRootMenu;\n this.service.closeAllContextMenu$.next({ sender: sender }); // Close all menus on scroll or resize\n }\n\n /** @ignore */\n @HostBinding('class')\n get __hostClass(): any {\n return [\n 'ax-menu-container',\n `ax-orientation-${this.orientation()}`,\n 'ax-action-list',\n 'ax-action-list-vertical',\n ];\n }\n}\n","<ng-content select=\"ax-menu-item,ax-divider,ax-title,ng-container\"></ng-content>\n\n<ng-container\n *ngFor=\"let node of items()\"\n [ngTemplateOutlet]=\"Recursion\"\n [ngTemplateOutletContext]=\"{ $implicit: node }\"\n>\n</ng-container>\n<ng-template #Recursion let-item>\n @if (item.group?.title) {\n <ax-title>{{ item.group?.title }}</ax-title>\n }\n <ax-menu-item [name]=\"item.name\" [data]=\"item.data\" [disabled]=\"item.disabled\" [color]=\"item.color\">\n <ax-prefix>\n @if (item.icon) {\n <ax-icon [icon]=\"item.icon\"> </ax-icon>\n }\n </ax-prefix>\n @if (item.text) {\n <ax-text>{{ item.text }}</ax-text>\n }\n @if (item.suffix) {\n <ax-suffix>\n <ax-text>{{ item.suffix.text }}</ax-text>\n </ax-suffix>\n }\n <ng-container\n *ngFor=\"let child of item.items\"\n [ngTemplateOutlet]=\"Recursion\"\n [ngTemplateOutletContext]=\"{ $implicit: child }\"\n ></ng-container>\n </ax-menu-item>\n @if (item.break) {\n <ax-divider></ax-divider>\n }\n</ng-template>\n","import { AXOrientation, NXComponent } from '@acorex/components/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n HostBinding,\n inject,\n input,\n output,\n ViewEncapsulation,\n} from '@angular/core';\nimport { AXMenuService } from './menu.service';\nimport {\n AXMenuCloseTrigger,\n AXMenuItem,\n AXMenuItemClickBaseEvent,\n AXMenuOpenTrigger,\n AXRootMenu,\n} from './menu.types';\n\nexport type AXMenuItemsClickEvent = AXMenuItemClickBaseEvent<AXMenuComponent>;\n\n/**\n * Represents a menu component that displays menu items.\n * @category Components\n */\n@Component({\n selector: 'ax-menu',\n templateUrl: './menu.component.html',\n styleUrls: ['./menu.component.scss'],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [\n AXMenuService,\n {\n provide: AXRootMenu,\n useExisting: AXMenuComponent,\n },\n ],\n})\nexport class AXMenuComponent extends NXComponent {\n orientation = input<AXOrientation>('horizontal');\n\n openOn = input<AXMenuOpenTrigger>('hover');\n\n closeOn = input<AXMenuCloseTrigger>('leave');\n\n service = inject(AXMenuService);\n\n onItemClick = output<AXMenuItemsClickEvent>();\n\n items = input<AXMenuItem[]>([]);\n\n hasArrow = input<boolean>(true);\n\n /** @ignore */\n @HostBinding('class')\n get __hostClass(): string[] {\n return [\n 'ax-root-menu',\n 'ax-action-list',\n `ax-action-list-${this.orientation()}`,\n `${!this.hasArrow() ? 'ax-hide-arrow' : ''}`,\n ];\n }\n\n public close() {\n this.service.closeAll$.next();\n }\n}\n","import { AXDecoratorModule } from '@acorex/components/decorators';\nimport { AXLoadingModule } from '@acorex/components/loading';\nimport { AXPopoverModule } from '@acorex/components/popover';\nimport { AXTranslationModule } from '@acorex/core/translation';\nimport { OverlayModule } from '@angular/cdk/overlay';\nimport { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\n\nimport { AXContextMenuComponent } from './context-menu.component';\nimport { AXMenuItemComponent } from './menu-item.component';\nimport { AXMenuComponent } from './menu.component';\n\nconst COMPONENT = [AXMenuItemComponent, AXMenuComponent, AXContextMenuComponent];\nconst MODULES = [AXDecoratorModule, AXLoadingModule, AXTranslationModule, OverlayModule, AXPopoverModule];\n\n@NgModule({\n declarations: [...COMPONENT],\n imports: [CommonModule, ...MODULES],\n exports: [...COMPONENT],\n providers: [],\n})\nexport class AXMenuModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i3.AXMenuItemComponent"],"mappings":";;;;;;;;;;;;;;;;MAMsB,UAAU,CAAA;AAO/B;MAEqB,uBAAuB,CAAA;AAAG;MAE1B,UAAU,CAAA;AAgB/B;AAEK,MAAO,wBAA8D,SAAQ,YAAe,CAAA;AAAlG,IAAA,WAAA,GAAA;;QAME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,YAAY,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;+GAAZ,YAAY,EAAA,YAAA,EAAA,CATN,mBAAmB,EAAE,eAAe,EAAE,sBAAsB,CAAA,EAAA,OAAA,EAAA,CAKnE,YAAY,EAJP,iBAAiB,EAAE,eAAe,EAAE,mBAAmB,EAAE,aAAa,EAAE,eAAe,aADrF,mBAAmB,EAAE,eAAe,EAAE,sBAAsB,CAAA,EAAA,CAAA,CAAA;+GASlE,YAAY,EAAA,OAAA,EAAA,CAJb,YAAY,EAAK,OAAO,CAAA,EAAA,CAAA,CAAA;;2FAIvB,YAAY,EAAA,UAAA,EAAA,CAAA;kBANxB,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,YAAY,EAAE,CAAC,GAAG,SAAS,CAAC;AAC5B,oBAAA,OAAO,EAAE,CAAC,YAAY,EAAE,GAAG,OAAO,CAAC;AACnC,oBAAA,OAAO,EAAE,CAAC,GAAG,SAAS,CAAC;AACvB,oBAAA,SAAS,EAAE,EAAE;AACd,iBAAA;;;ACpBD;;AAEG;;;;"}
@@ -1,13 +1,18 @@
1
1
  import { MXInputBaseValueComponent, MXLookComponent, AXComponent, AXFocusableComponent, AXClearableComponent, AXValuableComponent } from '@acorex/components/common';
2
2
  import * as i0 from '@angular/core';
3
- import { forwardRef, Component, ViewEncapsulation, ChangeDetectionStrategy, ViewChild, Input, signal, inject, afterNextRender, NgModule } from '@angular/core';
3
+ import { input, forwardRef, Component, ViewEncapsulation, ChangeDetectionStrategy, ViewChild, Input, signal, inject, afterNextRender, NgModule } from '@angular/core';
4
4
  import * as i1 from '@angular/forms';
5
5
  import { NG_VALUE_ACCESSOR, FormsModule } from '@angular/forms';
6
6
  import { classes } from 'polytype';
7
+ import * as i2 from '@acorex/components/badge';
8
+ import { AXBadgeModule } from '@acorex/components/badge';
7
9
  import { AXButtonModule } from '@acorex/components/button';
8
10
  import { AXDecoratorModule } from '@acorex/components/decorators';
9
11
  import * as i1$1 from '@acorex/components/progress-bar';
10
12
  import { AXProgressBarModule } from '@acorex/components/progress-bar';
13
+ import * as i4 from '@acorex/core/translation';
14
+ import { AXTranslationModule } from '@acorex/core/translation';
15
+ import * as i3 from '@angular/common';
11
16
  import { CommonModule } from '@angular/common';
12
17
 
13
18
  /**
@@ -30,6 +35,14 @@ class AXPasswordBoxComponent extends classes((MXInputBaseValueComponent), MXLook
30
35
  * A flag for showing or hiding password button.
31
36
  */
32
37
  this.showToggleButton = true;
38
+ /**
39
+ * Hint status.
40
+ */
41
+ this.showHint = input(false);
42
+ /**
43
+ * Progress status.
44
+ */
45
+ this.showProgress = input(false);
33
46
  }
34
47
  /** @ignore */
35
48
  _handleModelChange(value) {
@@ -49,7 +62,7 @@ class AXPasswordBoxComponent extends classes((MXInputBaseValueComponent), MXLook
49
62
  }
50
63
  }
51
64
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: AXPasswordBoxComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
52
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.0", type: AXPasswordBoxComponent, selector: "ax-password-box", inputs: { readonly: "readonly", disabled: "disabled", tabIndex: "tabIndex", placeholder: "placeholder", value: "value", state: "state", name: "name", id: "id", look: "look", autoComplete: "autoComplete", showToggleButton: "showToggleButton", classNames: ["class", "classNames"] }, outputs: { valueChange: "valueChange", stateChange: "stateChange", onValueChanged: "onValueChanged", onBlur: "onBlur", onFocus: "onFocus", readonlyChange: "readonlyChange", disabledChange: "disabledChange", onKeyDown: "onKeyDown", onKeyUp: "onKeyUp", onKeyPress: "onKeyPress" }, providers: [
65
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.0", type: AXPasswordBoxComponent, selector: "ax-password-box", inputs: { readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: false, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: false, isRequired: false, transformFunction: null }, tabIndex: { classPropertyName: "tabIndex", publicName: "tabIndex", isSignal: false, isRequired: false, transformFunction: null }, placeholder: { classPropertyName: "placeholder", publicName: "placeholder", isSignal: false, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: false, isRequired: false, transformFunction: null }, state: { classPropertyName: "state", publicName: "state", isSignal: false, isRequired: false, transformFunction: null }, name: { classPropertyName: "name", publicName: "name", isSignal: false, isRequired: false, transformFunction: null }, id: { classPropertyName: "id", publicName: "id", isSignal: false, isRequired: false, transformFunction: null }, look: { classPropertyName: "look", publicName: "look", isSignal: false, isRequired: false, transformFunction: null }, autoComplete: { classPropertyName: "autoComplete", publicName: "autoComplete", isSignal: false, isRequired: false, transformFunction: null }, showToggleButton: { classPropertyName: "showToggleButton", publicName: "showToggleButton", isSignal: false, isRequired: false, transformFunction: null }, classNames: { classPropertyName: "classNames", publicName: "class", isSignal: false, isRequired: false, transformFunction: null }, showHint: { classPropertyName: "showHint", publicName: "showHint", isSignal: true, isRequired: false, transformFunction: null }, showProgress: { classPropertyName: "showProgress", publicName: "showProgress", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { valueChange: "valueChange", stateChange: "stateChange", onValueChanged: "onValueChanged", onBlur: "onBlur", onFocus: "onFocus", readonlyChange: "readonlyChange", disabledChange: "disabledChange", onKeyDown: "onKeyDown", onKeyUp: "onKeyUp", onKeyPress: "onKeyPress" }, providers: [
53
66
  { provide: AXComponent, useExisting: AXPasswordBoxComponent },
54
67
  { provide: AXFocusableComponent, useExisting: AXPasswordBoxComponent },
55
68
  { provide: AXClearableComponent, useExisting: AXPasswordBoxComponent },
@@ -59,7 +72,7 @@ class AXPasswordBoxComponent extends classes((MXInputBaseValueComponent), MXLook
59
72
  useExisting: forwardRef(() => AXPasswordBoxComponent),
60
73
  multi: true,
61
74
  },
62
- ], viewQueries: [{ propertyName: "input", first: true, predicate: ["input"], descendants: true }], usesInheritance: true, ngImport: i0, template: "<div class=\"ax-editor-container ax-look-{{ look }} {{ classNames }}\" [class.ax-state-disabled]=\"disabled\">\n <ng-content select=\"ax-prefix\"> </ng-content>\n <input\n #input\n class=\"ax-input\"\n [name]=\"name\"\n [type]=\"_type\"\n [id]=\"id\"\n [attr.placeholder]=\"placeholder\"\n [class.ax-state-disabled]=\"disabled\"\n [class.ax-state-readonly]=\"readonly\"\n [disabled]=\"disabled\"\n [readonly]=\"readonly\"\n [tabindex]=\"tabIndex\"\n [ngModel]=\"value\"\n [attr.autocomplete]=\"autoComplete\"\n (ngModelChange)=\"_handleModelChange($event)\"\n (keydown)=\"emitOnKeydownEvent($event)\"\n (keyup)=\"emitOnKeyupEvent($event)\"\n (keypress)=\"emitOnKeypressEvent($event)\"\n (focus)=\"emitOnFocusEvent($event)\"\n (blur)=\"emitOnBlurEvent($event)\"\n />\n @if (value && !disabled && !readonly) {\n <ng-content select=\"ax-clear-button\"></ng-content>\n }\n @if (showToggleButton) {\n <button type=\"button\" class=\"ax-general-button ax-button-icon\" (click)=\"toggleType()\" [tabIndex]=\"-1\">\n <span class=\"ax-icon {{ _icon }}\"></span>\n </button>\n }\n <ng-content select=\"ax-suffix\"> </ng-content>\n <ng-content select=\"ax-validation-rule\"> </ng-content>\n</div>\n<div class=\"ax-error-container\"></div>\n\n<div class=\"ax-strength-validation-container\">\n <ng-content select=\"ax-password-strength-validation\"></ng-content>\n</div>\n", styles: [".ax-strength-validation-container{margin-top:.5rem}\n"], dependencies: [{ kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
75
+ ], viewQueries: [{ propertyName: "input", first: true, predicate: ["input"], descendants: true }], usesInheritance: true, ngImport: i0, template: "<div class=\"ax-editor-container ax-look-{{ look }} {{ classNames }}\" [class.ax-state-disabled]=\"disabled\">\n <ng-content select=\"ax-prefix\"> </ng-content>\n <input\n #input\n class=\"ax-input\"\n [name]=\"name\"\n [type]=\"_type\"\n [id]=\"id\"\n [attr.placeholder]=\"placeholder\"\n [class.ax-state-disabled]=\"disabled\"\n [class.ax-state-readonly]=\"readonly\"\n [disabled]=\"disabled\"\n [readonly]=\"readonly\"\n [tabindex]=\"tabIndex\"\n [ngModel]=\"value\"\n [attr.autocomplete]=\"autoComplete\"\n (ngModelChange)=\"_handleModelChange($event)\"\n (keydown)=\"emitOnKeydownEvent($event)\"\n (keyup)=\"emitOnKeyupEvent($event)\"\n (keypress)=\"emitOnKeypressEvent($event)\"\n (focus)=\"emitOnFocusEvent($event)\"\n (blur)=\"emitOnBlurEvent($event)\"\n />\n @if (value && !disabled && !readonly) {\n <ng-content select=\"ax-clear-button\"></ng-content>\n }\n @if (showToggleButton) {\n <button type=\"button\" class=\"ax-general-button ax-button-icon\" (click)=\"toggleType()\" [tabIndex]=\"-1\">\n <span class=\"ax-icon {{ _icon }}\"></span>\n </button>\n }\n <ng-content select=\"ax-suffix\"> </ng-content>\n <ng-content select=\"ax-validation-rule\"> </ng-content>\n</div>\n<div class=\"ax-error-container\"></div>\n\n<div class=\"ax-strength-validation-container\">\n <ng-content select=\"ax-password-strength-validation\" [showHint]=\"showStrength()\"></ng-content>\n</div>\n", styles: [".ax-strength-validation-container{margin-top:.25rem}\n"], dependencies: [{ kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
63
76
  }
64
77
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: AXPasswordBoxComponent, decorators: [{
65
78
  type: Component,
@@ -84,7 +97,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImpor
84
97
  useExisting: forwardRef(() => AXPasswordBoxComponent),
85
98
  multi: true,
86
99
  },
87
- ], template: "<div class=\"ax-editor-container ax-look-{{ look }} {{ classNames }}\" [class.ax-state-disabled]=\"disabled\">\n <ng-content select=\"ax-prefix\"> </ng-content>\n <input\n #input\n class=\"ax-input\"\n [name]=\"name\"\n [type]=\"_type\"\n [id]=\"id\"\n [attr.placeholder]=\"placeholder\"\n [class.ax-state-disabled]=\"disabled\"\n [class.ax-state-readonly]=\"readonly\"\n [disabled]=\"disabled\"\n [readonly]=\"readonly\"\n [tabindex]=\"tabIndex\"\n [ngModel]=\"value\"\n [attr.autocomplete]=\"autoComplete\"\n (ngModelChange)=\"_handleModelChange($event)\"\n (keydown)=\"emitOnKeydownEvent($event)\"\n (keyup)=\"emitOnKeyupEvent($event)\"\n (keypress)=\"emitOnKeypressEvent($event)\"\n (focus)=\"emitOnFocusEvent($event)\"\n (blur)=\"emitOnBlurEvent($event)\"\n />\n @if (value && !disabled && !readonly) {\n <ng-content select=\"ax-clear-button\"></ng-content>\n }\n @if (showToggleButton) {\n <button type=\"button\" class=\"ax-general-button ax-button-icon\" (click)=\"toggleType()\" [tabIndex]=\"-1\">\n <span class=\"ax-icon {{ _icon }}\"></span>\n </button>\n }\n <ng-content select=\"ax-suffix\"> </ng-content>\n <ng-content select=\"ax-validation-rule\"> </ng-content>\n</div>\n<div class=\"ax-error-container\"></div>\n\n<div class=\"ax-strength-validation-container\">\n <ng-content select=\"ax-password-strength-validation\"></ng-content>\n</div>\n", styles: [".ax-strength-validation-container{margin-top:.5rem}\n"] }]
100
+ ], template: "<div class=\"ax-editor-container ax-look-{{ look }} {{ classNames }}\" [class.ax-state-disabled]=\"disabled\">\n <ng-content select=\"ax-prefix\"> </ng-content>\n <input\n #input\n class=\"ax-input\"\n [name]=\"name\"\n [type]=\"_type\"\n [id]=\"id\"\n [attr.placeholder]=\"placeholder\"\n [class.ax-state-disabled]=\"disabled\"\n [class.ax-state-readonly]=\"readonly\"\n [disabled]=\"disabled\"\n [readonly]=\"readonly\"\n [tabindex]=\"tabIndex\"\n [ngModel]=\"value\"\n [attr.autocomplete]=\"autoComplete\"\n (ngModelChange)=\"_handleModelChange($event)\"\n (keydown)=\"emitOnKeydownEvent($event)\"\n (keyup)=\"emitOnKeyupEvent($event)\"\n (keypress)=\"emitOnKeypressEvent($event)\"\n (focus)=\"emitOnFocusEvent($event)\"\n (blur)=\"emitOnBlurEvent($event)\"\n />\n @if (value && !disabled && !readonly) {\n <ng-content select=\"ax-clear-button\"></ng-content>\n }\n @if (showToggleButton) {\n <button type=\"button\" class=\"ax-general-button ax-button-icon\" (click)=\"toggleType()\" [tabIndex]=\"-1\">\n <span class=\"ax-icon {{ _icon }}\"></span>\n </button>\n }\n <ng-content select=\"ax-suffix\"> </ng-content>\n <ng-content select=\"ax-validation-rule\"> </ng-content>\n</div>\n<div class=\"ax-error-container\"></div>\n\n<div class=\"ax-strength-validation-container\">\n <ng-content select=\"ax-password-strength-validation\" [showHint]=\"showStrength()\"></ng-content>\n</div>\n", styles: [".ax-strength-validation-container{margin-top:.25rem}\n"] }]
88
101
  }], propDecorators: { input: [{
89
102
  type: ViewChild,
90
103
  args: ['input']
@@ -100,45 +113,78 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImpor
100
113
  class AXPasswordStrengthValidationComponent {
101
114
  constructor() {
102
115
  this.passwordStrength = signal(0);
103
- this.strengthLabel = signal('week');
116
+ this.updatedPassword = signal('');
117
+ this.strengthLabel = signal('fragile');
104
118
  this.strengthLabelColor = signal('danger');
105
119
  this.parent = inject(AXPasswordBoxComponent);
120
+ this.isLenghtgraterThan8 = signal({ regex: /.{8,}/, state: false });
121
+ this.isUseUpperCase = signal({ regex: /[A-Z]/, state: false });
122
+ this.isUseLowerCase = signal({ regex: /[a-z]/, state: false });
123
+ this.isUseNumber = signal({ regex: /\d/, state: false });
124
+ this.isUseSpecialCharacter = signal({
125
+ regex: /[!@#$%^&*(),.?":{}|<>]/,
126
+ state: false,
127
+ });
106
128
  this.#onComponentInit = afterNextRender(() => {
107
129
  this.parent.onValueChanged.subscribe((v) => {
108
130
  if (v.value) {
109
- this.checkPasswordStrength(v.value);
131
+ this.updatedPassword.set(v.value);
110
132
  }
111
133
  else {
112
- this.passwordStrength.set(0);
134
+ this.updatedPassword.set('');
113
135
  }
136
+ this.checkPasswordStrength();
114
137
  });
115
138
  });
116
139
  }
117
140
  #onComponentInit;
118
- checkPasswordStrength(password) {
141
+ checkRegexHandler(inter) {
142
+ if (inter().regex.test(this.updatedPassword())) {
143
+ inter.update((prev) => ({ ...prev, state: true }));
144
+ return true;
145
+ }
146
+ inter.update((prev) => ({ ...prev, state: false }));
147
+ return false;
148
+ }
149
+ checkPasswordStrength() {
119
150
  let strength = 0;
120
- const criteria = [/.{8,}/, /[A-Z]/, /[a-z]/, /\d/, /[!@#$%^&*(),.?":{}|<>]/];
121
- criteria.forEach((regex) => {
122
- if (regex.test(password))
123
- strength++;
124
- });
125
- this.strengthLabel.set(strength <= 2 ? 'Week' : strength == 3 ? 'So-so' : strength == 4 ? 'Good' : 'Great');
151
+ this.checkRegexHandler(this.isLenghtgraterThan8) && strength++;
152
+ this.checkRegexHandler(this.isUseUpperCase) && strength++;
153
+ this.checkRegexHandler(this.isUseLowerCase) && strength++;
154
+ this.checkRegexHandler(this.isUseNumber) && strength++;
155
+ this.checkRegexHandler(this.isUseSpecialCharacter) && strength++;
156
+ const strengthLabels = ['fragile', 'fragile', 'weak', 'good', 'strong', 'unbreakable'];
157
+ this.strengthLabel.set(strengthLabels[strength]);
126
158
  this.strengthLabelColor.set(strength <= 2 ? 'danger' : strength <= 3 ? 'warning' : 'success');
127
- this.passwordStrength.set((strength * 100) / criteria.length);
159
+ this.passwordStrength.set((strength * 100) / 5);
128
160
  }
129
161
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: AXPasswordStrengthValidationComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
130
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.0", type: AXPasswordStrengthValidationComponent, selector: "ax-password-strength-validation", ngImport: i0, template: "<ax-progress-bar\n [color]=\"strengthLabelColor()\"\n [progress]=\"passwordStrength()\"\n [height]=\"4\"\n></ax-progress-bar>\n<small\n class=\"ax-whitespace-nowrap ax-px-3 ax-text-center\"\n [class.ax-text-danger]=\"strengthLabelColor() === 'danger'\"\n [class.ax-text-warning]=\"strengthLabelColor() === 'warning'\"\n [class.ax-text-success]=\"strengthLabelColor() === 'success'\"\n >{{ strengthLabel() }}\n</small>\n", dependencies: [{ kind: "component", type: i1$1.AXProgressBarComponent, selector: "ax-progress-bar", inputs: ["color", "mode", "progress", "height"], outputs: ["ValueChange", "sizeChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
162
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.0", type: AXPasswordStrengthValidationComponent, selector: "ax-password-strength-validation", ngImport: i0, template: "@if (parent.showProgress()) {\n <small\n class=\"ax-state-password\"\n [class.ax-text-red]=\"strengthLabelColor() === 'danger'\"\n [class.ax-text-orange]=\"strengthLabelColor() === 'warning'\"\n [class.ax-text-green]=\"strengthLabelColor() === 'success'\"\n >\n {{ strengthLabel() | translate | async }}\n </small>\n\n <ax-progress-bar\n [color]=\"strengthLabelColor()\"\n [progress]=\"passwordStrength()\"\n [height]=\"4\"\n ></ax-progress-bar>\n}\n@if (parent.showHint()) {\n <div class=\"ax-hint-container\">\n <small class=\"ax-hint-state\">\n <ax-badge [color]=\"isLenghtgraterThan8().state ? 'success' : 'danger'\"></ax-badge>\n <span [class.ax-line]=\"isLenghtgraterThan8().state\">\n {{ 'at-least-8-characters' | translate | async }}\n </span>\n </small>\n <small class=\"ax-hint-state\" [class.ax-line]=\"isUseUpperCase().state\">\n <ax-badge [color]=\"isUseUpperCase().state ? 'success' : 'danger'\"></ax-badge>\n <span>\n {{ 'english-upper-case-letter' | translate | async }}\n </span>\n </small>\n <small class=\"ax-hint-state\" [class.ax-line]=\"isUseLowerCase().state\">\n <ax-badge [color]=\"isUseLowerCase().state ? 'success' : 'danger'\"></ax-badge>\n <span>\n {{ 'english-lower-case-letter' | translate | async }}\n </span>\n </small>\n <small class=\"ax-hint-state\" [class.ax-line]=\"isUseNumber().state\">\n <ax-badge [color]=\"isUseNumber().state ? 'success' : 'danger'\"></ax-badge\n ><span> {{ 'digits' | translate | async }} </span>\n </small>\n <small class=\"ax-hint-state\" [class.ax-line]=\"isUseSpecialCharacter().state\">\n <ax-badge [color]=\"isUseSpecialCharacter().state ? 'success' : 'danger'\"></ax-badge>\n <span>\n {{ 'special-character' | translate | async }}\n </span>\n </small>\n </div>\n}\n", styles: [".ax-state-password.ax-text-red{color:rgb(var(--ax-color-danger-500))}.ax-state-password.ax-text-orange{color:rgb(var(--ax-color-warning-500))}.ax-state-password.ax-text-green{color:rgb(var(--ax-color-success-500))}.ax-hint-container{display:flex;flex-direction:column;gap:.5rem;padding-top:.5rem}.ax-hint-container .ax-line{text-decoration:line-through}\n"], dependencies: [{ kind: "component", type: i1$1.AXProgressBarComponent, selector: "ax-progress-bar", inputs: ["color", "mode", "progress", "height"], outputs: ["ValueChange", "sizeChange"] }, { kind: "component", type: i2.AXBadgeComponent, selector: "ax-badge", inputs: ["color", "look", "text"] }, { kind: "pipe", type: i3.AsyncPipe, name: "async" }, { kind: "pipe", type: i4.AXTranslatorPipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
131
163
  }
132
164
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: AXPasswordStrengthValidationComponent, decorators: [{
133
165
  type: Component,
134
- args: [{ selector: 'ax-password-strength-validation', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<ax-progress-bar\n [color]=\"strengthLabelColor()\"\n [progress]=\"passwordStrength()\"\n [height]=\"4\"\n></ax-progress-bar>\n<small\n class=\"ax-whitespace-nowrap ax-px-3 ax-text-center\"\n [class.ax-text-danger]=\"strengthLabelColor() === 'danger'\"\n [class.ax-text-warning]=\"strengthLabelColor() === 'warning'\"\n [class.ax-text-success]=\"strengthLabelColor() === 'success'\"\n >{{ strengthLabel() }}\n</small>\n" }]
166
+ args: [{ selector: 'ax-password-strength-validation', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "@if (parent.showProgress()) {\n <small\n class=\"ax-state-password\"\n [class.ax-text-red]=\"strengthLabelColor() === 'danger'\"\n [class.ax-text-orange]=\"strengthLabelColor() === 'warning'\"\n [class.ax-text-green]=\"strengthLabelColor() === 'success'\"\n >\n {{ strengthLabel() | translate | async }}\n </small>\n\n <ax-progress-bar\n [color]=\"strengthLabelColor()\"\n [progress]=\"passwordStrength()\"\n [height]=\"4\"\n ></ax-progress-bar>\n}\n@if (parent.showHint()) {\n <div class=\"ax-hint-container\">\n <small class=\"ax-hint-state\">\n <ax-badge [color]=\"isLenghtgraterThan8().state ? 'success' : 'danger'\"></ax-badge>\n <span [class.ax-line]=\"isLenghtgraterThan8().state\">\n {{ 'at-least-8-characters' | translate | async }}\n </span>\n </small>\n <small class=\"ax-hint-state\" [class.ax-line]=\"isUseUpperCase().state\">\n <ax-badge [color]=\"isUseUpperCase().state ? 'success' : 'danger'\"></ax-badge>\n <span>\n {{ 'english-upper-case-letter' | translate | async }}\n </span>\n </small>\n <small class=\"ax-hint-state\" [class.ax-line]=\"isUseLowerCase().state\">\n <ax-badge [color]=\"isUseLowerCase().state ? 'success' : 'danger'\"></ax-badge>\n <span>\n {{ 'english-lower-case-letter' | translate | async }}\n </span>\n </small>\n <small class=\"ax-hint-state\" [class.ax-line]=\"isUseNumber().state\">\n <ax-badge [color]=\"isUseNumber().state ? 'success' : 'danger'\"></ax-badge\n ><span> {{ 'digits' | translate | async }} </span>\n </small>\n <small class=\"ax-hint-state\" [class.ax-line]=\"isUseSpecialCharacter().state\">\n <ax-badge [color]=\"isUseSpecialCharacter().state ? 'success' : 'danger'\"></ax-badge>\n <span>\n {{ 'special-character' | translate | async }}\n </span>\n </small>\n </div>\n}\n", styles: [".ax-state-password.ax-text-red{color:rgb(var(--ax-color-danger-500))}.ax-state-password.ax-text-orange{color:rgb(var(--ax-color-warning-500))}.ax-state-password.ax-text-green{color:rgb(var(--ax-color-success-500))}.ax-hint-container{display:flex;flex-direction:column;gap:.5rem;padding-top:.5rem}.ax-hint-container .ax-line{text-decoration:line-through}\n"] }]
135
167
  }] });
136
168
 
137
169
  const COMPONENT = [AXPasswordBoxComponent, AXPasswordStrengthValidationComponent];
138
- const MODULES = [CommonModule, FormsModule, AXButtonModule, AXDecoratorModule, AXProgressBarModule];
170
+ const MODULES = [
171
+ CommonModule,
172
+ FormsModule,
173
+ AXButtonModule,
174
+ AXDecoratorModule,
175
+ AXProgressBarModule,
176
+ AXBadgeModule,
177
+ AXTranslationModule,
178
+ ];
139
179
  class AXPasswordBoxModule {
140
180
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: AXPasswordBoxModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
141
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.0", ngImport: i0, type: AXPasswordBoxModule, declarations: [AXPasswordBoxComponent, AXPasswordStrengthValidationComponent], imports: [CommonModule, FormsModule, AXButtonModule, AXDecoratorModule, AXProgressBarModule], exports: [AXPasswordBoxComponent, AXPasswordStrengthValidationComponent] }); }
181
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.0", ngImport: i0, type: AXPasswordBoxModule, declarations: [AXPasswordBoxComponent, AXPasswordStrengthValidationComponent], imports: [CommonModule,
182
+ FormsModule,
183
+ AXButtonModule,
184
+ AXDecoratorModule,
185
+ AXProgressBarModule,
186
+ AXBadgeModule,
187
+ AXTranslationModule], exports: [AXPasswordBoxComponent, AXPasswordStrengthValidationComponent] }); }
142
188
  static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: AXPasswordBoxModule, imports: [MODULES] }); }
143
189
  }
144
190
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: AXPasswordBoxModule, decorators: [{
@@ -1 +1 @@
1
- {"version":3,"file":"acorex-components-password-box.mjs","sources":["../../../../libs/components/password-box/src/lib/password-box.component.ts","../../../../libs/components/password-box/src/lib/password-box.component.html","../../../../libs/components/password-box/src/lib/password-strength-validation/password-strength-validation.component.ts","../../../../libs/components/password-box/src/lib/password-strength-validation/password-strength-validation.component.html","../../../../libs/components/password-box/src/lib/password-box.module.ts","../../../../libs/components/password-box/src/acorex-components-password-box.ts"],"sourcesContent":["import {\n AXClearableComponent,\n AXComponent,\n AXFocusableComponent,\n AXValuableComponent,\n MXInputBaseValueComponent,\n MXLookComponent,\n} from '@acorex/components/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n Input,\n ViewChild,\n ViewEncapsulation,\n forwardRef,\n} from '@angular/core';\nimport { NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { classes } from 'polytype';\n\n/**\n * The Textbox is a component which detects user interaction and triggers a corresponding event\n *\n * @category Components\n */\n@Component({\n selector: 'ax-password-box',\n templateUrl: 'password-box.component.html',\n inputs: ['readonly', 'disabled', 'tabIndex', 'placeholder', 'value', 'state', 'name', 'id', 'look'],\n styles: `\n .ax-strength-validation-container {\n margin-top: 0.5rem;\n }\n `,\n outputs: [\n 'valueChange',\n 'stateChange',\n 'onValueChanged',\n 'onBlur',\n 'onFocus',\n 'readonlyChange',\n 'disabledChange',\n 'onKeyDown',\n 'onKeyUp',\n 'onKeyPress',\n ],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n\n providers: [\n { provide: AXComponent, useExisting: AXPasswordBoxComponent },\n { provide: AXFocusableComponent, useExisting: AXPasswordBoxComponent },\n { provide: AXClearableComponent, useExisting: AXPasswordBoxComponent },\n { provide: AXValuableComponent, useExisting: AXPasswordBoxComponent },\n {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => AXPasswordBoxComponent),\n multi: true,\n },\n ],\n})\nexport class AXPasswordBoxComponent extends classes(MXInputBaseValueComponent<string>, MXLookComponent) {\n /** @ignore */\n @ViewChild('input') input: ElementRef<HTMLInputElement>;\n\n /** @ignore */\n protected _type: 'password' | 'text' = 'password';\n\n /** @ignore */\n protected _icon: 'ax-icon-visibility' | 'ax-icon-visibility-off' = 'ax-icon-visibility';\n\n /**\n * Sets the autocomplete behavior for the input field.\n */\n @Input()\n autoComplete: 'current-password' | 'new-password' | 'one-time-code' | 'off' = 'one-time-code';\n\n /**\n * A flag for showing or hiding password button.\n */\n @Input()\n showToggleButton = true;\n\n /**\n * Defines custom CSS classes to apply to the component.\n */\n @Input('class')\n classNames: string;\n\n /** @ignore */\n _handleModelChange(value: string) {\n this.commitValue(value, true);\n }\n\n /**\n * Toggles the input type between 'password' and 'text' to show or hide the password.\n */\n toggleType() {\n if (this._type === 'password') {\n this._type = 'text';\n this._icon = 'ax-icon-visibility-off';\n } else {\n this._type = 'password';\n this._icon = 'ax-icon-visibility';\n }\n }\n\n // @HostBinding('class')\n // get __hostClass(): string[] {\n // return ['ax-editor-container', `ax-look-${this.look}`, `${this.disabled ? 'ax-state-disabled' : ''}`];\n // }\n}\n","<div class=\"ax-editor-container ax-look-{{ look }} {{ classNames }}\" [class.ax-state-disabled]=\"disabled\">\n <ng-content select=\"ax-prefix\"> </ng-content>\n <input\n #input\n class=\"ax-input\"\n [name]=\"name\"\n [type]=\"_type\"\n [id]=\"id\"\n [attr.placeholder]=\"placeholder\"\n [class.ax-state-disabled]=\"disabled\"\n [class.ax-state-readonly]=\"readonly\"\n [disabled]=\"disabled\"\n [readonly]=\"readonly\"\n [tabindex]=\"tabIndex\"\n [ngModel]=\"value\"\n [attr.autocomplete]=\"autoComplete\"\n (ngModelChange)=\"_handleModelChange($event)\"\n (keydown)=\"emitOnKeydownEvent($event)\"\n (keyup)=\"emitOnKeyupEvent($event)\"\n (keypress)=\"emitOnKeypressEvent($event)\"\n (focus)=\"emitOnFocusEvent($event)\"\n (blur)=\"emitOnBlurEvent($event)\"\n />\n @if (value && !disabled && !readonly) {\n <ng-content select=\"ax-clear-button\"></ng-content>\n }\n @if (showToggleButton) {\n <button type=\"button\" class=\"ax-general-button ax-button-icon\" (click)=\"toggleType()\" [tabIndex]=\"-1\">\n <span class=\"ax-icon {{ _icon }}\"></span>\n </button>\n }\n <ng-content select=\"ax-suffix\"> </ng-content>\n <ng-content select=\"ax-validation-rule\"> </ng-content>\n</div>\n<div class=\"ax-error-container\"></div>\n\n<div class=\"ax-strength-validation-container\">\n <ng-content select=\"ax-password-strength-validation\"></ng-content>\n</div>\n","import {\n afterNextRender,\n ChangeDetectionStrategy,\n Component,\n inject,\n signal,\n ViewEncapsulation,\n} from '@angular/core';\nimport { AXPasswordBoxComponent } from '../password-box.component';\n\n@Component({\n selector: 'ax-password-strength-validation',\n templateUrl: './password-strength-validation.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n})\nexport class AXPasswordStrengthValidationComponent {\n protected passwordStrength = signal(0);\n protected strengthLabel = signal('week');\n protected strengthLabelColor = signal('danger');\n protected parent = inject(AXPasswordBoxComponent);\n\n #onComponentInit = afterNextRender(() => {\n this.parent.onValueChanged.subscribe((v) => {\n if (v.value) {\n this.checkPasswordStrength(v.value);\n } else {\n this.passwordStrength.set(0);\n }\n });\n });\n\n protected checkPasswordStrength(password: string) {\n let strength = 0;\n const criteria = [/.{8,}/, /[A-Z]/, /[a-z]/, /\\d/, /[!@#$%^&*(),.?\":{}|<>]/];\n criteria.forEach((regex) => {\n if (regex.test(password)) strength++;\n });\n this.strengthLabel.set(\n strength <= 2 ? 'Week' : strength == 3 ? 'So-so' : strength == 4 ? 'Good' : 'Great',\n );\n this.strengthLabelColor.set(strength <= 2 ? 'danger' : strength <= 3 ? 'warning' : 'success');\n this.passwordStrength.set((strength * 100) / criteria.length);\n }\n}\n","<ax-progress-bar\n [color]=\"strengthLabelColor()\"\n [progress]=\"passwordStrength()\"\n [height]=\"4\"\n></ax-progress-bar>\n<small\n class=\"ax-whitespace-nowrap ax-px-3 ax-text-center\"\n [class.ax-text-danger]=\"strengthLabelColor() === 'danger'\"\n [class.ax-text-warning]=\"strengthLabelColor() === 'warning'\"\n [class.ax-text-success]=\"strengthLabelColor() === 'success'\"\n >{{ strengthLabel() }}\n</small>\n","import { AXButtonModule } from '@acorex/components/button';\nimport { AXDecoratorModule } from '@acorex/components/decorators';\nimport { AXProgressBarModule } from '@acorex/components/progress-bar';\nimport { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { FormsModule } from '@angular/forms';\nimport { AXPasswordBoxComponent } from './password-box.component';\nimport { AXPasswordStrengthValidationComponent } from './password-strength-validation/password-strength-validation.component';\n\nconst COMPONENT = [AXPasswordBoxComponent, AXPasswordStrengthValidationComponent];\nconst MODULES = [CommonModule, FormsModule, AXButtonModule, AXDecoratorModule, AXProgressBarModule];\n\n@NgModule({\n declarations: [...COMPONENT],\n imports: [...MODULES],\n exports: [...COMPONENT],\n providers: [],\n})\nexport class AXPasswordBoxModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1"],"mappings":";;;;;;;;;;;;AAoBA;;;;AAIG;AAqCG,MAAO,sBAAuB,SAAQ,OAAO,EAAC,yBAAiC,GAAE,eAAe,CAAC,CAAA;AApCvG,IAAA,WAAA,GAAA;;;QAyCY,IAAK,CAAA,KAAA,GAAwB,UAAU;;QAGvC,IAAK,CAAA,KAAA,GAAoD,oBAAoB;AAEvF;;AAEG;QAEH,IAAY,CAAA,YAAA,GAAkE,eAAe;AAE7F;;AAEG;QAEH,IAAgB,CAAA,gBAAA,GAAG,IAAI;AA8BxB;;AArBC,IAAA,kBAAkB,CAAC,KAAa,EAAA;AAC9B,QAAA,IAAI,CAAC,WAAW,CAAC,KAAK,EAAE,IAAI,CAAC;;AAG/B;;AAEG;IACH,UAAU,GAAA;AACR,QAAA,IAAI,IAAI,CAAC,KAAK,KAAK,UAAU,EAAE;AAC7B,YAAA,IAAI,CAAC,KAAK,GAAG,MAAM;AACnB,YAAA,IAAI,CAAC,KAAK,GAAG,wBAAwB;;aAChC;AACL,YAAA,IAAI,CAAC,KAAK,GAAG,UAAU;AACvB,YAAA,IAAI,CAAC,KAAK,GAAG,oBAAoB;;;8GA1C1B,sBAAsB,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAtB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,sBAAsB,EAZtB,QAAA,EAAA,iBAAA,EAA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AAQ;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;;;ACjBD;;AAEG;;;;"}
1
+ {"version":3,"file":"acorex-components-password-box.mjs","sources":["../../../../libs/components/password-box/src/lib/password-box.component.ts","../../../../libs/components/password-box/src/lib/password-box.component.html","../../../../libs/components/password-box/src/lib/password-strength-validation/password-strength-validation.component.ts","../../../../libs/components/password-box/src/lib/password-strength-validation/password-strength-validation.component.html","../../../../libs/components/password-box/src/lib/password-box.module.ts","../../../../libs/components/password-box/src/acorex-components-password-box.ts"],"sourcesContent":["import {\n AXClearableComponent,\n AXComponent,\n AXFocusableComponent,\n AXValuableComponent,\n MXInputBaseValueComponent,\n MXLookComponent,\n} from '@acorex/components/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n Input,\n ViewChild,\n ViewEncapsulation,\n forwardRef,\n input,\n} from '@angular/core';\nimport { NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { classes } from 'polytype';\n\n/**\n * The Textbox is a component which detects user interaction and triggers a corresponding event\n *\n * @category Components\n */\n@Component({\n selector: 'ax-password-box',\n templateUrl: 'password-box.component.html',\n inputs: ['readonly', 'disabled', 'tabIndex', 'placeholder', 'value', 'state', 'name', 'id', 'look'],\n styles: `\n .ax-strength-validation-container {\n margin-top: 0.25rem;\n }\n `,\n outputs: [\n 'valueChange',\n 'stateChange',\n 'onValueChanged',\n 'onBlur',\n 'onFocus',\n 'readonlyChange',\n 'disabledChange',\n 'onKeyDown',\n 'onKeyUp',\n 'onKeyPress',\n ],\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n\n providers: [\n { provide: AXComponent, useExisting: AXPasswordBoxComponent },\n { provide: AXFocusableComponent, useExisting: AXPasswordBoxComponent },\n { provide: AXClearableComponent, useExisting: AXPasswordBoxComponent },\n { provide: AXValuableComponent, useExisting: AXPasswordBoxComponent },\n {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => AXPasswordBoxComponent),\n multi: true,\n },\n ],\n})\nexport class AXPasswordBoxComponent extends classes(MXInputBaseValueComponent<string>, MXLookComponent) {\n /** @ignore */\n @ViewChild('input') input: ElementRef<HTMLInputElement>;\n\n /** @ignore */\n protected _type: 'password' | 'text' = 'password';\n\n /** @ignore */\n protected _icon: 'ax-icon-visibility' | 'ax-icon-visibility-off' = 'ax-icon-visibility';\n\n /**\n * Sets the autocomplete behavior for the input field.\n */\n @Input()\n autoComplete: 'current-password' | 'new-password' | 'one-time-code' | 'off' = 'one-time-code';\n\n /**\n * A flag for showing or hiding password button.\n */\n @Input()\n showToggleButton = true;\n\n /**\n * Defines custom CSS classes to apply to the component.\n */\n @Input('class')\n classNames: string;\n\n /**\n * Hint status.\n */\n showHint = input(false);\n\n /**\n * Progress status.\n */\n showProgress = input(false);\n\n /** @ignore */\n _handleModelChange(value: string) {\n this.commitValue(value, true);\n }\n\n /**\n * Toggles the input type between 'password' and 'text' to show or hide the password.\n */\n toggleType() {\n if (this._type === 'password') {\n this._type = 'text';\n this._icon = 'ax-icon-visibility-off';\n } else {\n this._type = 'password';\n this._icon = 'ax-icon-visibility';\n }\n }\n\n // @HostBinding('class')\n // get __hostClass(): string[] {\n // return ['ax-editor-container', `ax-look-${this.look}`, `${this.disabled ? 'ax-state-disabled' : ''}`];\n // }\n}\n","<div class=\"ax-editor-container ax-look-{{ look }} {{ classNames }}\" [class.ax-state-disabled]=\"disabled\">\n <ng-content select=\"ax-prefix\"> </ng-content>\n <input\n #input\n class=\"ax-input\"\n [name]=\"name\"\n [type]=\"_type\"\n [id]=\"id\"\n [attr.placeholder]=\"placeholder\"\n [class.ax-state-disabled]=\"disabled\"\n [class.ax-state-readonly]=\"readonly\"\n [disabled]=\"disabled\"\n [readonly]=\"readonly\"\n [tabindex]=\"tabIndex\"\n [ngModel]=\"value\"\n [attr.autocomplete]=\"autoComplete\"\n (ngModelChange)=\"_handleModelChange($event)\"\n (keydown)=\"emitOnKeydownEvent($event)\"\n (keyup)=\"emitOnKeyupEvent($event)\"\n (keypress)=\"emitOnKeypressEvent($event)\"\n (focus)=\"emitOnFocusEvent($event)\"\n (blur)=\"emitOnBlurEvent($event)\"\n />\n @if (value && !disabled && !readonly) {\n <ng-content select=\"ax-clear-button\"></ng-content>\n }\n @if (showToggleButton) {\n <button type=\"button\" class=\"ax-general-button ax-button-icon\" (click)=\"toggleType()\" [tabIndex]=\"-1\">\n <span class=\"ax-icon {{ _icon }}\"></span>\n </button>\n }\n <ng-content select=\"ax-suffix\"> </ng-content>\n <ng-content select=\"ax-validation-rule\"> </ng-content>\n</div>\n<div class=\"ax-error-container\"></div>\n\n<div class=\"ax-strength-validation-container\">\n <ng-content select=\"ax-password-strength-validation\" [showHint]=\"showStrength()\"></ng-content>\n</div>\n","import {\n afterNextRender,\n ChangeDetectionStrategy,\n Component,\n inject,\n signal,\n ViewEncapsulation,\n} from '@angular/core';\nimport { AXPasswordBoxComponent } from '../password-box.component';\n\n@Component({\n selector: 'ax-password-strength-validation',\n templateUrl: './password-strength-validation.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n styleUrl: './password-strength-validation.component.scss',\n})\nexport class AXPasswordStrengthValidationComponent {\n protected passwordStrength = signal(0);\n protected updatedPassword = signal('');\n protected strengthLabel = signal('fragile');\n protected strengthLabelColor = signal('danger');\n protected parent = inject(AXPasswordBoxComponent);\n\n protected isLenghtgraterThan8 = signal({ regex: /.{8,}/, state: false });\n protected isUseUpperCase = signal({ regex: /[A-Z]/, state: false });\n protected isUseLowerCase = signal({ regex: /[a-z]/, state: false });\n protected isUseNumber = signal({ regex: /\\d/, state: false });\n protected isUseSpecialCharacter = signal({\n regex: /[!@#$%^&*(),.?\":{}|<>]/,\n state: false,\n });\n\n #onComponentInit = afterNextRender(() => {\n this.parent.onValueChanged.subscribe((v) => {\n if (v.value) {\n this.updatedPassword.set(v.value);\n } else {\n this.updatedPassword.set('');\n }\n this.checkPasswordStrength();\n });\n });\n\n private checkRegexHandler(inter) {\n if (inter().regex.test(this.updatedPassword())) {\n inter.update((prev) => ({ ...prev, state: true }));\n return true;\n }\n inter.update((prev) => ({ ...prev, state: false }));\n return false;\n }\n\n protected checkPasswordStrength() {\n let strength = 0;\n\n this.checkRegexHandler(this.isLenghtgraterThan8) && strength++;\n this.checkRegexHandler(this.isUseUpperCase) && strength++;\n this.checkRegexHandler(this.isUseLowerCase) && strength++;\n this.checkRegexHandler(this.isUseNumber) && strength++;\n this.checkRegexHandler(this.isUseSpecialCharacter) && strength++;\n\n const strengthLabels = ['fragile', 'fragile', 'weak', 'good', 'strong', 'unbreakable'];\n this.strengthLabel.set(strengthLabels[strength]);\n this.strengthLabelColor.set(strength <= 2 ? 'danger' : strength <= 3 ? 'warning' : 'success');\n this.passwordStrength.set((strength * 100) / 5);\n }\n}\n","@if (parent.showProgress()) {\n <small\n class=\"ax-state-password\"\n [class.ax-text-red]=\"strengthLabelColor() === 'danger'\"\n [class.ax-text-orange]=\"strengthLabelColor() === 'warning'\"\n [class.ax-text-green]=\"strengthLabelColor() === 'success'\"\n >\n {{ strengthLabel() | translate | async }}\n </small>\n\n <ax-progress-bar\n [color]=\"strengthLabelColor()\"\n [progress]=\"passwordStrength()\"\n [height]=\"4\"\n ></ax-progress-bar>\n}\n@if (parent.showHint()) {\n <div class=\"ax-hint-container\">\n <small class=\"ax-hint-state\">\n <ax-badge [color]=\"isLenghtgraterThan8().state ? 'success' : 'danger'\"></ax-badge>\n <span [class.ax-line]=\"isLenghtgraterThan8().state\">\n {{ 'at-least-8-characters' | translate | async }}\n </span>\n </small>\n <small class=\"ax-hint-state\" [class.ax-line]=\"isUseUpperCase().state\">\n <ax-badge [color]=\"isUseUpperCase().state ? 'success' : 'danger'\"></ax-badge>\n <span>\n {{ 'english-upper-case-letter' | translate | async }}\n </span>\n </small>\n <small class=\"ax-hint-state\" [class.ax-line]=\"isUseLowerCase().state\">\n <ax-badge [color]=\"isUseLowerCase().state ? 'success' : 'danger'\"></ax-badge>\n <span>\n {{ 'english-lower-case-letter' | translate | async }}\n </span>\n </small>\n <small class=\"ax-hint-state\" [class.ax-line]=\"isUseNumber().state\">\n <ax-badge [color]=\"isUseNumber().state ? 'success' : 'danger'\"></ax-badge\n ><span> {{ 'digits' | translate | async }} </span>\n </small>\n <small class=\"ax-hint-state\" [class.ax-line]=\"isUseSpecialCharacter().state\">\n <ax-badge [color]=\"isUseSpecialCharacter().state ? 'success' : 'danger'\"></ax-badge>\n <span>\n {{ 'special-character' | translate | async }}\n </span>\n </small>\n </div>\n}\n","import { AXBadgeModule } from '@acorex/components/badge';\nimport { AXButtonModule } from '@acorex/components/button';\nimport { AXDecoratorModule } from '@acorex/components/decorators';\nimport { AXProgressBarModule } from '@acorex/components/progress-bar';\nimport { AXTranslationModule } from '@acorex/core/translation';\nimport { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { FormsModule } from '@angular/forms';\nimport { AXPasswordBoxComponent } from './password-box.component';\nimport { AXPasswordStrengthValidationComponent } from './password-strength-validation/password-strength-validation.component';\n\nconst COMPONENT = [AXPasswordBoxComponent, AXPasswordStrengthValidationComponent];\nconst MODULES = [\n CommonModule,\n FormsModule,\n AXButtonModule,\n AXDecoratorModule,\n AXProgressBarModule,\n AXBadgeModule,\n AXTranslationModule,\n];\n\n@NgModule({\n declarations: [...COMPONENT],\n imports: [...MODULES],\n exports: [...COMPONENT],\n providers: [],\n})\nexport class AXPasswordBoxModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1"],"mappings":";;;;;;;;;;;;;;;;;AAqBA;;;;AAIG;AAqCG,MAAO,sBAAuB,SAAQ,OAAO,EAAC,yBAAiC,GAA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CAAA;8GAAnB,mBAAmB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;AAAnB,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,mBAAmB,EAjBb,YAAA,EAAA,CAAA,sBAAsB,EAAE,qCAAqC,aAE9E,YAAY;YACZ,WAAW;YACX,cAAc;YACd,iBAAiB;YACjB,mBAAmB;YACnB,aAAa;YACb,mBAAmB,CAAA,EAAA,OAAA,EAAA,CARF,sBAAsB,EAAE,qCAAqC,CAAA,EAAA,CAAA,CAAA;AAiBnE,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,mBAAmB,YAJjB,OAAO,CAAA,EAAA,CAAA,CAAA;;2FAIT,mBAAmB,EAAA,UAAA,EAAA,CAAA;kBAN/B,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;;;AC3BD;;AAEG;;;;"}
@@ -3,10 +3,10 @@ import { AXPlatform, isBrowser } from '@acorex/core/platform';
3
3
  import { AXHtmlUtil } from '@acorex/core/utils';
4
4
  import { Overlay } from '@angular/cdk/overlay';
5
5
  import { TemplatePortal, ComponentPortal } from '@angular/cdk/portal';
6
+ import { DOCUMENT, CommonModule } from '@angular/common';
6
7
  import * as i0 from '@angular/core';
7
8
  import { inject, EventEmitter, ElementRef, TemplateRef, Component, ViewEncapsulation, ChangeDetectionStrategy, Input, ViewChild, Output, NgModule } from '@angular/core';
8
9
  import { fromEvent, delay } from 'rxjs';
9
- import { CommonModule } from '@angular/common';
10
10
 
11
11
  /**
12
12
  * @category Components
@@ -16,6 +16,7 @@ class AXPopoverComponent extends MXBaseComponent {
16
16
  constructor() {
17
17
  super(...arguments);
18
18
  this.#platform = inject(AXPlatform);
19
+ this.document = inject(DOCUMENT);
19
20
  /** @ignore */
20
21
  this._platform = inject(AXPlatform);
21
22
  /** @ignore */
@@ -286,7 +287,7 @@ class AXPopoverComponent extends MXBaseComponent {
286
287
  //__axContext__
287
288
  const el = c.nativeEvent.target;
288
289
  if (!this.isActionsheetStyle) {
289
- if (el == document) {
290
+ if (el == this.document) {
290
291
  this.close();
291
292
  return;
292
293
  }
@@ -342,7 +343,7 @@ class AXPopoverComponent extends MXBaseComponent {
342
343
  /** @ignore */
343
344
  saveFocus() {
344
345
  if (isBrowser()) {
345
- this._lastActiveElement = document.activeElement;
346
+ this._lastActiveElement = this.document.activeElement;
346
347
  }
347
348
  }
348
349
  /** @ignore */