@acorex/components 19.2.0 → 19.3.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (53) hide show
  1. package/common/lib/classes/components.class.d.ts +1 -0
  2. package/decorators/lib/components/close-button.component.d.ts +2 -1
  3. package/fesm2022/acorex-components-action-sheet.mjs +1 -1
  4. package/fesm2022/acorex-components-action-sheet.mjs.map +1 -1
  5. package/fesm2022/acorex-components-collapse.mjs +7 -5
  6. package/fesm2022/acorex-components-collapse.mjs.map +1 -1
  7. package/fesm2022/acorex-components-common.mjs.map +1 -1
  8. package/fesm2022/acorex-components-conversation.mjs +2 -2
  9. package/fesm2022/acorex-components-conversation.mjs.map +1 -1
  10. package/fesm2022/acorex-components-decorators.mjs +21 -5
  11. package/fesm2022/acorex-components-decorators.mjs.map +1 -1
  12. package/fesm2022/acorex-components-grid-layout-builder.mjs +286 -23
  13. package/fesm2022/acorex-components-grid-layout-builder.mjs.map +1 -1
  14. package/fesm2022/acorex-components-media-viewer.mjs +245 -75
  15. package/fesm2022/acorex-components-media-viewer.mjs.map +1 -1
  16. package/fesm2022/acorex-components-notification.mjs +1 -1
  17. package/fesm2022/acorex-components-notification.mjs.map +1 -1
  18. package/fesm2022/acorex-components-pdf-reader.mjs +39 -0
  19. package/fesm2022/acorex-components-pdf-reader.mjs.map +1 -0
  20. package/fesm2022/acorex-components-popup.mjs +1 -1
  21. package/fesm2022/acorex-components-popup.mjs.map +1 -1
  22. package/fesm2022/acorex-components-select-box.mjs +1 -1
  23. package/fesm2022/acorex-components-select-box.mjs.map +1 -1
  24. package/fesm2022/acorex-components-step-wizard.mjs +5 -3
  25. package/fesm2022/acorex-components-step-wizard.mjs.map +1 -1
  26. package/fesm2022/acorex-components-tabs.mjs +13 -12
  27. package/fesm2022/acorex-components-tabs.mjs.map +1 -1
  28. package/fesm2022/acorex-components-toast.mjs +136 -123
  29. package/fesm2022/acorex-components-toast.mjs.map +1 -1
  30. package/fesm2022/acorex-components-video-player.mjs +37 -0
  31. package/fesm2022/acorex-components-video-player.mjs.map +1 -0
  32. package/grid-layout-builder/lib/grid-layout-container.component.d.ts +183 -1
  33. package/grid-layout-builder/lib/grid-layout-widget.component.d.ts +84 -1
  34. package/media-viewer/index.d.ts +0 -1
  35. package/media-viewer/lib/media-viewer-container/media-viewer-container.component.d.ts +21 -6
  36. package/media-viewer/lib/media-viewer-tools/file-info/file-info.component.d.ts +1 -2
  37. package/media-viewer/lib/media-viewer-tools/pdf-reader/pdf-reader.component.d.ts +3 -3
  38. package/media-viewer/lib/media-viewer-tools/video-player/video-player.component.d.ts +3 -3
  39. package/media-viewer/lib/media-viewer.module.d.ts +17 -15
  40. package/package.json +9 -1
  41. package/pdf-reader/README.md +3 -0
  42. package/pdf-reader/index.d.ts +2 -0
  43. package/pdf-reader/lib/pdf-reader/pdf-reader.component.d.ts +8 -0
  44. package/pdf-reader/lib/pdf-reader.module.d.ts +7 -0
  45. package/tabs/lib/tabs.class.d.ts +1 -1
  46. package/toast/lib/toast.class.d.ts +1 -0
  47. package/toast/lib/toast.component.d.ts +4 -0
  48. package/toast/lib/toast.service.d.ts +3 -4
  49. package/video-player/README.md +3 -0
  50. package/video-player/index.d.ts +2 -0
  51. package/video-player/lib/video-player/video-player.component.d.ts +6 -0
  52. package/video-player/lib/video-player.module.d.ts +7 -0
  53. package/media-viewer/lib/media-viewer-thumbnail/media-viewer-thumbnail.component.d.ts +0 -11
@@ -1 +1 @@
1
- {"version":3,"file":"acorex-components-grid-layout-builder.mjs","sources":["../../../../libs/components/grid-layout-builder/src/lib/grid-layout-widget.component.ts","../../../../libs/components/grid-layout-builder/src/lib/grid-layout-container.component.ts","../../../../libs/components/grid-layout-builder/src/lib/grid-layout-builder.module.ts","../../../../libs/components/grid-layout-builder/src/lib/types.ts","../../../../libs/components/grid-layout-builder/src/acorex-components-grid-layout-builder.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n inject,\n input,\n ViewEncapsulation,\n} from '@angular/core';\nimport { AXGridLayoutNode, AXGridLayoutWidgetCompElement } from './types';\n\n@Component({\n selector: 'ax-grid-layout-widget',\n template: ` <div class=\"grid-stack-item-content\">\n <ng-template #container></ng-template>\n <ng-content></ng-content>\n {{ options().content }}\n </div>`,\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n standalone: false,\n})\nexport class AXGridLayoutWidgetComponent {\n //public container = viewChild('container', { read: ViewContainerRef });\n //public ref: ComponentRef<AXGridLayoutWidgetComponent> | undefined;\n //public childWidget: BaseWidget | undefined;\n private readonly elementRef: ElementRef<AXGridLayoutWidgetCompElement> = inject(ElementRef);\n public el: AXGridLayoutWidgetCompElement = this.elementRef.nativeElement;\n\n private _options?: AXGridLayoutNode;\n\n public options = input(null, {\n transform: (val: AXGridLayoutNode) => {\n const grid = this.el.gridstackNode?.grid;\n if (grid) {\n grid.update(this.el, val);\n } else {\n this._options = { ...val, el: this.el };\n }\n return this.el.gridstackNode || this._options || { el: this.el };\n },\n });\n\n public clearOptions() {\n this._options = null;\n }\n\n constructor() {\n this.el._gridWidgetComp = this;\n }\n}\n","import {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n NgZone,\n ViewEncapsulation,\n WritableSignal,\n computed,\n contentChildren,\n effect,\n inject,\n input,\n model,\n output,\n signal,\n} from '@angular/core';\nimport { AXGridLayoutWidgetComponent } from './grid-layout-widget.component';\nimport {\n AXGridLayout,\n AXGridLayoutContainerCompElement,\n AXGridLayoutDroppedEvent,\n AXGridLayoutElementEvent,\n AXGridLayoutEventEvent,\n AXGridLayoutNode,\n AXGridLayoutNodesEvent,\n AXGridLayoutOptions,\n AXGridLayoutWidget,\n AXGridLayoutWidgetCompElement,\n AXGridLayoutWidgetElement,\n AXSaveCallback,\n} from './types';\n\n@Component({\n selector: 'ax-grid-layout-container',\n template: ` <ng-template #container></ng-template>\n <ng-content></ng-content>`,\n styleUrl: './grid-layout-container.scss',\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n standalone: false,\n})\nexport class AXGridLayoutContainerComponent {\n //CHILD\n private items = contentChildren(AXGridLayoutWidgetComponent);\n //private container = viewChild('container', { read: ViewContainerRef });\n\n //INPUT\n public options = input<AXGridLayoutOptions>();\n private calcOptions = computed(() => this.grid()?.opts || this.options() || {});\n\n //INJECT\n private readonly elementRef: ElementRef<AXGridLayoutContainerCompElement> = inject(ElementRef);\n private ngZone = inject(NgZone);\n\n //VARIABLE\n private grid: WritableSignal<AXGridLayout> = signal(null);\n private loaded?: boolean;\n private el: AXGridLayoutContainerCompElement = this.elementRef.nativeElement;\n //private ref: ComponentRef<AXGridLayoutContainerComponent> | undefined;\n\n //OUTPUTS\n protected onAdded = output<AXGridLayoutNodesEvent>();\n protected onChange = output<AXGridLayoutNodesEvent>();\n protected onDisable = output<AXGridLayoutEventEvent>();\n protected onDrag = output<AXGridLayoutElementEvent>();\n protected onDragStart = output<AXGridLayoutElementEvent>();\n protected onDragStop = output<AXGridLayoutElementEvent>();\n protected onDropped = output<AXGridLayoutDroppedEvent>();\n protected onEnable = output<AXGridLayoutEventEvent>();\n protected onRemoved = output<AXGridLayoutNodesEvent>();\n protected onResize = output<AXGridLayoutElementEvent>();\n protected onResizeStart = output<AXGridLayoutElementEvent>();\n protected onResizeStop = output<AXGridLayoutElementEvent>();\n protected isRendered = output<boolean>();\n\n //MODEL\n protected isEmpty = model(false);\n\n //LIFECYCLE\n constructor() {\n this.el._gridComp = this;\n }\n protected async ngOnInit(): Promise<void> {\n this.ngZone.runOutsideAngular(async () => {\n this.loaded = !!this.calcOptions()?.children?.length;\n const { GridStack } = await import('gridstack');\n this.grid.set(GridStack.init(this.calcOptions(), this.el));\n this.checkEmpty();\n });\n }\n protected ngOnDestroy(): void {\n this.unhookEvents(this.grid());\n this.grid()?.destroy();\n }\n\n //EFFECT\n private gridChange = effect(() => {\n if (this.grid()) {\n if (!this.loaded) this.updateAll();\n this.hookEvents(this.grid());\n this.isRendered.emit(true);\n console.log('Grid Rendered!');\n }\n });\n private childChange = effect(() => {\n if (this.items()) {\n this.updateAll();\n }\n });\n\n //METHOD\n private updateAll() {\n if (!this.grid()) return;\n const layout: AXGridLayoutWidget[] = [];\n this.items()?.forEach((item) => {\n layout.push(item.options());\n item.clearOptions();\n });\n this.grid().load(layout);\n }\n\n private checkEmpty() {\n if (this.grid()) {\n const isEmpty = !this.grid().engine.nodes.length;\n if (isEmpty === this.isEmpty()) return;\n this.isEmpty.set(isEmpty);\n }\n }\n //ADD LISTENERS\n private hookEvents(grid?: AXGridLayout): void {\n if (grid) {\n grid\n .on('added', (event: Event, nodes: AXGridLayoutNode[]) => {\n this.checkEmpty();\n this.onAdded.emit({ event, nodes });\n })\n .on('removed', (event: Event, nodes: AXGridLayoutNode[]) => {\n this.checkEmpty();\n this.onRemoved.emit({ event, nodes });\n })\n .on('change', (event: Event, nodes: AXGridLayoutNode[]) => this.onChange.emit({ event, nodes }))\n .on('disable', (event: Event) => this.onDisable.emit({ event }))\n .on('drag', (event: Event, el: AXGridLayoutWidgetElement) => this.onDrag.emit({ event, el }))\n .on('dragstart', (event: Event, el: AXGridLayoutWidgetElement) =>\n this.onDragStart.emit({ event, el }),\n )\n .on('dragstop', (event: Event, el: AXGridLayoutWidgetElement) => this.onDragStop.emit({ event, el }))\n .on('dropped', (event: Event, previousNode: AXGridLayoutNode, newNode: AXGridLayoutNode) =>\n this.onDropped.emit({ event, previousNode, newNode }),\n )\n .on('enable', (event: Event) => this.onEnable.emit({ event }))\n .on('resize', (event: Event, el: AXGridLayoutWidgetElement) => this.onResize.emit({ event, el }))\n .on('resizestart', (event: Event, el: AXGridLayoutWidgetElement) =>\n this.onResizeStart.emit({ event, el }),\n )\n .on('resizestop', (event: Event, el: AXGridLayoutWidgetElement) =>\n this.onResizeStop.emit({ event, el }),\n );\n }\n }\n\n //REMOVE LISTENERS\n private unhookEvents(grid?: AXGridLayout) {\n if (grid) {\n //grid.off('added change disable drag dragstart dragstop dropped enable removed resize resizestart resizestop' );\n grid.offAll();\n }\n }\n\n //PUBLIC METHODS\n public add(item: AXGridLayoutWidget, withAutoArrange = false): AXGridLayoutNode {\n if (withAutoArrange) {\n this.autoArrange();\n }\n return this.grid().addWidget(item).gridstackNode;\n }\n public remove(element: AXGridLayoutWidgetCompElement): AXGridLayout {\n return this.grid().removeWidget(element);\n }\n public clear(): AXGridLayout {\n return this.grid().removeAll();\n }\n private serializedData?: AXGridLayoutOptions;\n public save(saveContent = false, saveGridOpt = true, saveCallback?: AXSaveCallback): AXGridLayoutOptions {\n return (this.serializedData = this.grid().save(\n saveContent,\n saveGridOpt,\n saveCallback,\n ) as AXGridLayoutOptions);\n }\n\n public async load(\n serializedData: AXGridLayoutOptions = this.serializedData,\n cleanBeforeLoad = true,\n ): Promise<AXGridLayout> {\n if (cleanBeforeLoad) {\n this.grid().removeAll();\n }\n const { GridStack } = await import('gridstack');\n return GridStack.addGrid(this.el, serializedData);\n }\n\n public autoArrange() {\n this.grid().compact();\n }\n\n public setlockable(state: boolean, recurse?: boolean) {\n this.grid().enableMove(state, recurse);\n }\n\n public setResizable(state: boolean, recurse?: boolean) {\n this.grid().enableResize(state, recurse);\n }\n\n public getChildren(): AXGridLayoutNode[] {\n return this.grid().engine.nodes;\n }\n\n public async setupDraggable(dragIn?: string | HTMLElement[], widgets?: AXGridLayoutWidget) {\n if (typeof dragIn === 'string') {\n document.querySelectorAll(dragIn).forEach((item) => {\n if (!item.classList.contains('grid-stack-item')) {\n item.classList.add('grid-stack-item');\n }\n });\n }\n const { GridStack } = await import('gridstack');\n GridStack.setupDragIn(dragIn, undefined, [widgets]);\n }\n\n public setOption(options: AXGridLayoutOptions) {\n this.grid().opts = options;\n }\n\n //TODO doesnt work!\n public rotate(element: AXGridLayoutWidgetCompElement) {\n this.grid().rotate(element);\n }\n\n public setColumn(count: number) {\n this.grid().column(count, 'moveScale');\n }\n}\n","/**\n * gridstack.component.ts 11.1.1-dev\n * Copyright (c) 2022-2024 Alain Dumesny - see GridStack root license\n */\n\nimport { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\n\nimport { AXGridLayoutContainerComponent } from './grid-layout-container.component';\nimport { AXGridLayoutWidgetComponent } from './grid-layout-widget.component';\n\n@NgModule({\n imports: [CommonModule],\n declarations: [AXGridLayoutContainerComponent, AXGridLayoutWidgetComponent],\n exports: [AXGridLayoutContainerComponent, AXGridLayoutWidgetComponent],\n})\nexport class AXGridLayoutBuilderModule {\n // constructor() {\n // set globally our method to create the right widget type\n // GridStack.addRemoveCB = gsCreateNgComponents;\n // GridStack.saveCB = gsSaveAdditionalNgInfo;\n // }\n}\n","import { AXGridLayoutContainerComponent } from './grid-layout-container.component';\nimport { AXGridLayoutWidgetComponent } from './grid-layout-widget.component';\n//TYPES\nexport type AXGridLayoutNode = import('gridstack').GridStackNode;\nexport type AXGridLayout = import('gridstack').GridStack;\nexport type AXGridLayoutOptions = import('gridstack').GridStackOptions;\nexport type AXGridLayoutWidget = import('gridstack').GridStackWidget & { data?: any };\nexport type AXGridLayoutContainerElement = import('gridstack').GridHTMLElement;\nexport type AXGridLayoutWidgetElement = import('gridstack').GridItemHTMLElement;\n//EVENTS\nexport type AXGridLayoutEventEvent = { event: Event };\nexport type AXGridLayoutElementEvent = { event: Event; el: AXGridLayoutWidgetElement };\nexport type AXGridLayoutNodesEvent = { event: Event; nodes: AXGridLayoutNode[] };\nexport type AXGridLayoutDroppedEvent = {\n event: Event;\n previousNode: AXGridLayoutNode;\n newNode: AXGridLayoutNode;\n};\n//COMPONENTS\nexport interface AXGridLayoutContainerCompElement extends AXGridLayoutContainerElement {\n _gridComp?: AXGridLayoutContainerComponent;\n}\nexport interface AXGridLayoutWidgetCompElement extends AXGridLayoutWidgetElement {\n _gridWidgetComp?: AXGridLayoutWidgetComponent;\n}\n\n//Callback\nexport type AXSaveCallback = import('gridstack').SaveFcn;\n\n// //DYNAMIC\n// export type AXNgCompInputs = { [key: string]: any };\n// export type SelectorToType = { [key: string]: Type<object> }; // selector string to runtime Type mapping\n// export interface AXNgGridLayoutWidget extends AXGridLayoutWidget {\n// selector?: string; //Angular tag selector for this component to create at runtime\n// input?: AXNgCompInputs; // serialized data for the component input fields\n// subGridOpts?: AXNgGridLayoutOptions; // nested grid options\n// }\n// export interface AXNgGridLayoutNode extends AXGridLayoutNode {\n// selector?: string; // component type to create as content\n// }\n// export interface AXNgGridLayoutOptions extends AXGridLayoutOptions {\n// children?: AXNgGridLayoutWidget[];\n// subGridOpts?: AXNgGridLayoutOptions;\n// }\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;MAqBa,2BAA2B,CAAA;IAqB/B,YAAY,GAAA;AACjB,QAAA,IAAI,CAAC,QAAQ,GAAG,IAAI;;AAGtB,IAAA,WAAA,GAAA;;;;AArBiB,QAAA,IAAA,CAAA,UAAU,GAA8C,MAAM,CAAC,UAAU,CAAC;AACpF,QAAA,IAAA,CAAA,EAAE,GAAkC,IAAI,CAAC,UAAU,CAAC,aAAa;AAIjE,QAAA,IAAA,CAAA,OAAO,GAAG,KAAK,CAAC,IAAI,EAAE;AAC3B,YAAA,SAAS,EAAE,CAAC,GAAqB,KAAI;gBACnC,MAAM,IAAI,GAAG,IAAI,CAAC,EAAE,CAAC,aAAa,EAAE,IAAI;gBACxC,IAAI,IAAI,EAAE;oBACR,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,EAAE,EAAE,GAAG,CAAC;;qBACpB;AACL,oBAAA,IAAI,CAAC,QAAQ,GAAG,EAAE,GAAG,GAAG,EAAE,EAAE,EAAE,IAAI,CAAC,EAAE,EAAE;;AAEzC,gBAAA,OAAO,IAAI,CAAC,EAAE,CAAC,aAAa,IAAI,IAAI,CAAC,QAAQ,IAAI,EAAE,EAAE,EAAE,IAAI,CAAC,EAAE,EAAE;aACjE;AACF,SAAA,CAAC;AAOA,QAAA,IAAI,CAAC,EAAE,CAAC,eAAe,GAAG,IAAI;;8GA1BrB,2BAA2B,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,E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,EAAA,CAAA,CAAA;;2FAIX,yBAAyB,EAAA,UAAA,EAAA,CAAA;kBALrC,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,OAAO,EAAE,CAAC,YAAY,CAAC;AACvB,oBAAA,YAAY,EAAE,CAAC,8BAA8B,EAAE,2BAA2B,CAAC;AAC3E,oBAAA,OAAO,EAAE,CAAC,8BAA8B,EAAE,2BAA2B,CAAC;AACvE,iBAAA;;;ACcD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AC3CA;;AAEG;;;;"}
1
+ {"version":3,"file":"acorex-components-grid-layout-builder.mjs","sources":["../../../../libs/components/grid-layout-builder/src/lib/grid-layout-widget.component.ts","../../../../libs/components/grid-layout-builder/src/lib/grid-layout-container.component.ts","../../../../libs/components/grid-layout-builder/src/lib/grid-layout-builder.module.ts","../../../../libs/components/grid-layout-builder/src/lib/types.ts","../../../../libs/components/grid-layout-builder/src/acorex-components-grid-layout-builder.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n inject,\n input,\n ViewEncapsulation,\n} from '@angular/core';\nimport { AXGridLayoutNode, AXGridLayoutWidget, AXGridLayoutWidgetCompElement } from './types';\n\n/**\n * A component that represents a widget within the grid layout. It serves as an individual\n * item within a `gridstack` layout, providing options for customization and interaction.\n *\n * This widget component is used within the `AXGridLayoutContainerComponent` to manage the\n * layout of widgets in a grid system. The component interacts with the GridStack library\n * to offer features like resizing, movement, and customization of the widget's properties.\n *\n * @example\n * <ax-grid-layout-widget [options]=\"widgetOptions\">\n * <div>Widget Content</div>\n * </ax-grid-layout-widget>\n */\n@Component({\n selector: 'ax-grid-layout-widget',\n template: ` <div class=\"grid-stack-item-content\">\n <ng-template #container></ng-template>\n <ng-content></ng-content>\n {{ options().content }}\n </div>`,\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n standalone: false,\n})\nexport class AXGridLayoutWidgetComponent {\n /**\n * A reference to the native element of this widget component. It is used for interaction\n * with the underlying DOM element and for updating the widget properties via GridStack.\n */\n private readonly elementRef: ElementRef<AXGridLayoutWidgetCompElement> = inject(ElementRef);\n \n /**\n * The native element of the widget component.\n */\n public el: AXGridLayoutWidgetCompElement = this.elementRef.nativeElement;\n\n /**\n * The current options of the widget. These options are used to define the layout,\n * content, and behavior of the widget within the grid.\n *\n * @internal\n */\n private _options?: AXGridLayoutNode;\n\n /**\n * Input property that represents the widget's configuration options.\n *\n * The options include properties such as position, size, content, and other\n * configuration values. These options are updated dynamically.\n *\n * @param {AXGridLayoutNode} val The configuration object for the widget.\n * @returns {AXGridLayoutWidgetCompElement} The element associated with the widget.\n */\n public options = input(null, {\n transform: (val: AXGridLayoutNode) => {\n const grid = this.el.gridstackNode?.grid;\n if (grid) {\n grid.update(this.el, val);\n } else {\n this._options = { ...val, el: this.el };\n }\n return this.el.gridstackNode || this._options || { el: this.el };\n },\n });\n\n /**\n * Clears the widget's options.\n *\n * This method removes any existing options set for the widget and resets it\n * to its default state.\n */\n public clearOptions() {\n this._options = null;\n }\n\n /**\n * Constructor that initializes the widget component and sets the reference to\n * the grid widget component in the element's properties.\n */\n constructor() {\n this.el._gridWidgetComp = this;\n }\n\n /**\n * Removes this widget from the grid.\n *\n * This method interacts with GridStack to remove the widget from the layout.\n * Once removed, the widget will no longer be part of the grid.\n */\n public removeWidget() {\n this.el.gridstackNode.grid.removeWidget(this.el);\n }\n\n /**\n * Sets whether the widget can be locked (i.e., not resizable).\n *\n * @param {boolean} state Whether the widget should be locked or not.\n * @remarks\n * If the widget is locked, it cannot be resized.\n */\n public setlockable(state: boolean): void {\n this.el.gridstackNode.grid.update(this.el, { noResize: state });\n }\n\n /**\n * Sets whether the widget can be resized.\n *\n * @param {boolean} state Whether the widget should be resizable or not.\n * @remarks\n * If the widget is resizable, the user can change its size by dragging.\n */\n public setResizable(state: boolean): void {\n this.el.gridstackNode.grid.update(this.el, { noMove: state });\n }\n\n /**\n * Updates the options of the widget.\n *\n * @param {AXGridLayoutWidget} options The new options to apply to the widget.\n */\n setOptions(options: AXGridLayoutWidget) {\n this.el.gridstackNode.grid.update(this.el, options);\n }\n\n /**\n * Retrieves the current options of the widget.\n *\n * @returns {AXGridLayoutNode} The current configuration options of the widget.\n * @remarks\n * This method provides access to the widget's layout and configuration.\n * If no specific options are set, it returns the default options.\n */\n getOptions(): AXGridLayoutNode {\n const gridstackNode = this.el.gridstackNode;\n if (gridstackNode) {\n return {\n ...gridstackNode,\n el: this.el,\n };\n }\n return this.options() || this._options || { el: this.el };\n }\n}\n","import {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n NgZone,\n ViewEncapsulation,\n WritableSignal,\n computed,\n contentChildren,\n effect,\n inject,\n input,\n model,\n output,\n signal,\n} from '@angular/core';\nimport { AXGridLayoutWidgetComponent } from './grid-layout-widget.component';\nimport {\n AXGridLayout,\n AXGridLayoutContainerCompElement,\n AXGridLayoutDroppedEvent,\n AXGridLayoutElementEvent,\n AXGridLayoutEventEvent,\n AXGridLayoutNode,\n AXGridLayoutNodesEvent,\n AXGridLayoutOptions,\n AXGridLayoutWidget,\n AXGridLayoutWidgetCompElement,\n AXGridLayoutWidgetElement,\n AXSaveCallback,\n} from './types';\n\n/**\n * The `AXGridLayoutContainerComponent` is an Angular component that acts as a wrapper for the GridStack library.\n * It provides a flexible grid layout system for arranging items within a container. It integrates with GridStack.js\n * and allows dynamic manipulation of grid items (widgets), including adding, removing, resizing, and dragging.\n *\n * This component uses Angular's reactive signals, outputs, and lifecycle hooks to manage grid state and interactions.\n */\n@Component({\n selector: 'ax-grid-layout-container',\n template: ` <ng-template #container></ng-template>\n <ng-content></ng-content>`,\n styleUrl: './grid-layout-container.scss',\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n standalone: false,\n})\nexport class AXGridLayoutContainerComponent {\n private serializedData?: AXGridLayoutOptions;\n /**\n * Content children elements of type `AXGridLayoutWidgetComponent` that are dynamically managed within the grid.\n */\n private items = contentChildren(AXGridLayoutWidgetComponent);\n\n /**\n * Input that holds options for configuring the GridStack grid layout.\n */\n public options = input<AXGridLayoutOptions>();\n\n /**\n * A computed signal that merges the provided `options` with the grid's existing configuration (if any).\n */\n private calcOptions = computed(() => this.grid()?.opts || this.options() || {});\n\n /**\n * A reference to the native element of the container component.\n */\n private readonly elementRef: ElementRef<AXGridLayoutContainerCompElement> = inject(ElementRef);\n\n /**\n * Angular's NgZone for running code outside Angular's change detection.\n */\n private ngZone = inject(NgZone);\n\n /**\n * A writable signal representing the current state of the grid.\n */\n private grid: WritableSignal<AXGridLayout> = signal(null);\n\n /**\n * Flag indicating whether the grid has been loaded with content.\n */\n private loaded?: boolean;\n\n /**\n * A reference to the native element representing the grid container.\n */\n private el: AXGridLayoutContainerCompElement = this.elementRef.nativeElement;\n\n // Outputs\n\n /**\n * Output event emitted when a widget is added to the grid.\n */\n protected onAdded = output<AXGridLayoutNodesEvent>();\n\n /**\n * Output event emitted when a widget or layout is changed.\n */\n protected onChange = output<AXGridLayoutNodesEvent>();\n\n /**\n * Output event emitted when the grid is disabled.\n */\n protected onDisable = output<AXGridLayoutEventEvent>();\n\n /**\n * Output event emitted during a drag operation on a widget.\n */\n protected onDrag = output<AXGridLayoutElementEvent>();\n\n /**\n * Output event emitted when drag starts on a widget.\n */\n protected onDragStart = output<AXGridLayoutElementEvent>();\n\n /**\n * Output event emitted when drag stops on a widget.\n */\n protected onDragStop = output<AXGridLayoutElementEvent>();\n\n /**\n * Output event emitted when a widget is dropped on the grid.\n */\n protected onDropped = output<AXGridLayoutDroppedEvent>();\n\n /**\n * Output event emitted when the grid is enabled.\n */\n protected onEnable = output<AXGridLayoutEventEvent>();\n\n /**\n * Output event emitted when a widget is removed from the grid.\n */\n protected onRemoved = output<AXGridLayoutNodesEvent>();\n\n /**\n * Output event emitted when a widget is resized.\n */\n protected onResize = output<AXGridLayoutElementEvent>();\n\n /**\n * Output event emitted when resizing starts on a widget.\n */\n protected onResizeStart = output<AXGridLayoutElementEvent>();\n\n /**\n * Output event emitted when resizing stops on a widget.\n */\n protected onResizeStop = output<AXGridLayoutElementEvent>();\n\n /**\n * Output event emitted when the grid is rendered.\n */\n protected isRendered = output<boolean>();\n\n // Model\n\n /**\n * Model that tracks whether the grid container is empty.\n */\n protected isEmpty = model(false);\n\n // Lifecycle\n\n /**\n * Initializes the grid layout component and sets up the GridStack grid.\n */\n constructor() {\n this.el._gridComp = this;\n }\n\n /**\n * Angular lifecycle hook that initializes the grid once the component is created.\n * It sets up GridStack and loads any initial layout configuration.\n */\n protected async ngOnInit(): Promise<void> {\n this.ngZone.runOutsideAngular(async () => {\n this.loaded = !!this.calcOptions()?.children?.length;\n const { GridStack } = await import('gridstack');\n this.grid.set(GridStack.init(this.calcOptions(), this.el));\n this.checkEmpty();\n });\n }\n\n /**\n * Angular lifecycle hook that cleans up resources when the component is destroyed.\n * It removes event listeners and destroys the GridStack instance.\n */\n protected ngOnDestroy(): void {\n this.unhookEvents(this.grid());\n this.grid()?.destroy();\n }\n\n // Effects\n\n /**\n * Effect that reacts to changes in the grid layout and updates the DOM accordingly.\n */\n private gridChange = effect(() => {\n if (this.grid()) {\n if (!this.loaded) this.updateAll();\n this.hookEvents(this.grid());\n this.isRendered.emit(true);\n console.log('Grid Rendered!');\n }\n });\n\n /**\n * Effect that reacts to changes in child widgets and updates the grid layout.\n */\n private childChange = effect(() => {\n if (this.items()) {\n this.updateAll();\n }\n });\n\n // Methods\n\n /**\n * Updates the grid layout with the current set of widgets, clearing previous options.\n */\n private updateAll() {\n if (!this.grid()) return;\n const layout: AXGridLayoutWidget[] = [];\n this.items()?.forEach((item) => {\n layout.push(item.options());\n item.clearOptions();\n });\n this.grid().load(layout);\n }\n\n /**\n * Checks whether the grid is empty and updates the `isEmpty` model accordingly.\n */\n private checkEmpty() {\n if (this.grid()) {\n const isEmpty = !this.grid().engine.nodes.length;\n if (isEmpty === this.isEmpty()) return;\n this.isEmpty.set(isEmpty);\n }\n }\n\n // Event Listeners\n\n /**\n * Hooks event listeners to the grid for various grid events (e.g., add, remove, drag, resize).\n */\n private hookEvents(grid?: AXGridLayout): void {\n if (grid) {\n grid\n .on('added', (event: Event, nodes: AXGridLayoutNode[]) => {\n this.checkEmpty();\n this.onAdded.emit({ event, nodes });\n })\n .on('removed', (event: Event, nodes: AXGridLayoutNode[]) => {\n this.checkEmpty();\n this.onRemoved.emit({ event, nodes });\n })\n .on('change', (event: Event, nodes: AXGridLayoutNode[]) => this.onChange.emit({ event, nodes }))\n .on('disable', (event: Event) => this.onDisable.emit({ event }))\n .on('drag', (event: Event, el: AXGridLayoutWidgetElement) => this.onDrag.emit({ event, el }))\n .on('dragstart', (event: Event, el: AXGridLayoutWidgetElement) =>\n this.onDragStart.emit({ event, el }),\n )\n .on('dragstop', (event: Event, el: AXGridLayoutWidgetElement) => this.onDragStop.emit({ event, el }))\n .on('dropped', (event: Event, previousNode: AXGridLayoutNode, newNode: AXGridLayoutNode) =>\n this.onDropped.emit({ event, previousNode, newNode }),\n )\n .on('enable', (event: Event) => this.onEnable.emit({ event }))\n .on('resize', (event: Event, el: AXGridLayoutWidgetElement) => this.onResize.emit({ event, el }))\n .on('resizestart', (event: Event, el: AXGridLayoutWidgetElement) =>\n this.onResizeStart.emit({ event, el }),\n )\n .on('resizestop', (event: Event, el: AXGridLayoutWidgetElement) =>\n this.onResizeStop.emit({ event, el }),\n );\n }\n }\n\n /**\n * Removes all event listeners from the grid.\n */\n private unhookEvents(grid?: AXGridLayout) {\n if (grid) {\n grid.offAll();\n }\n }\n\n // Public Methods\n\n /**\n * Adds a widget to the grid layout. Optionally arranges the grid after adding the widget.\n *\n * @param item The widget to add.\n * @param withAutoArrange If true, the grid will be auto-arranged after adding the widget.\n * @returns The added widget's layout node.\n */\n public add(item: AXGridLayoutWidget, withAutoArrange = false): AXGridLayoutNode {\n if (withAutoArrange) {\n this.autoArrange();\n }\n return this.grid().addWidget(item).gridstackNode;\n }\n\n /**\n * Removes a widget from the grid layout.\n *\n * @param element The widget element to remove.\n * @returns The updated grid instance.\n */\n public remove(element: AXGridLayoutWidgetCompElement): AXGridLayout {\n return this.grid().removeWidget(element);\n }\n\n /**\n * Clears all widgets from the grid layout.\n *\n * @returns The updated grid instance.\n */\n public clear(): AXGridLayout {\n return this.grid().removeAll();\n }\n\n /**\n * Saves the current state of the grid and its widgets.\n *\n * @param saveContent If true, the content of the widgets will be saved.\n * @param saveGridOpt If true, the grid options will be saved.\n * @param saveCallback Optional callback to invoke after saving the grid state.\n * @returns The saved grid layout options.\n */\n public save(saveContent = false, saveGridOpt = true, saveCallback?: AXSaveCallback): AXGridLayoutOptions {\n return (this.serializedData = this.grid().save(\n saveContent,\n saveGridOpt,\n saveCallback,\n ) as AXGridLayoutOptions);\n }\n\n /**\n * Loads a serialized grid layout configuration into the grid.\n *\n * @param serializedData The serialized grid options to load.\n * @param cleanBeforeLoad If true, the grid will be cleared before loading the new layout.\n * @returns A promise that resolves to the loaded grid instance.\n */\n public async load(\n serializedData: AXGridLayoutOptions = this.serializedData,\n cleanBeforeLoad = true,\n ): Promise<AXGridLayout> {\n if (cleanBeforeLoad) {\n this.grid().removeAll();\n }\n const { GridStack } = await import('gridstack');\n return GridStack.addGrid(this.el, serializedData);\n }\n\n /**\n * Automatically arranges the widgets within the grid layout.\n */\n public autoArrange() {\n this.grid().compact();\n }\n\n /**\n * Sets whether widgets in the grid can be moved (dragged).\n *\n * @param state If true, widgets are movable; otherwise, they are locked.\n * @param recurse If true, the setting is applied to nested widgets as well.\n */\n public setlockable(state: boolean, recurse?: boolean) {\n this.grid().enableMove(state, recurse);\n }\n\n /**\n * Sets whether widgets in the grid can be resized.\n *\n * @param state If true, widgets are resizable; otherwise, they are fixed.\n * @param recurse If true, the setting is applied to nested widgets as well.\n */\n public setResizable(state: boolean, recurse?: boolean) {\n this.grid().enableResize(state, recurse);\n }\n\n /**\n * Retrieves all the child nodes (widgets) in the grid layout.\n *\n * @returns An array of grid layout nodes representing the widgets.\n */\n public getChildren(): AXGridLayoutNode[] {\n return this.grid().engine.nodes;\n }\n\n /**\n * Sets up draggable functionality for external elements to be added to the grid.\n *\n * @param dragIn A CSS selector or an array of elements that can be dragged into the grid.\n * @param widgets An optional set of widgets that are draggable into the grid.\n */\n public async setupDraggable(dragIn?: string | HTMLElement[], widgets?: AXGridLayoutWidget) {\n if (typeof dragIn === 'string') {\n document.querySelectorAll(dragIn).forEach((item) => {\n if (!item.classList.contains('grid-stack-item')) {\n item.classList.add('grid-stack-item');\n }\n });\n }\n const { GridStack } = await import('gridstack');\n GridStack.setupDragIn(dragIn, undefined, [widgets]);\n }\n\n /**\n * Sets grid layout options.\n *\n * @param options The new grid layout options to apply.\n */\n public setOption(options: AXGridLayoutOptions) {\n this.grid().opts = options;\n }\n\n /**\n * Rotates a specific widget element in the grid layout.\n *\n * @param element The widget element to rotate.\n */\n public rotate(element: AXGridLayoutWidgetCompElement) {\n this.grid().rotate(element);\n }\n\n /**\n * Sets the number of columns in the grid layout.\n *\n * @param count The number of columns to set.\n */\n public setColumn(count: number) {\n this.grid().column(count, 'moveScale');\n }\n\n /**\n * Retrieves the current grid layout options.\n *\n * @returns The current grid options.\n */\n public getOptions() {\n return this.grid().opts;\n }\n}\n","/**\n * gridstack.component.ts 11.1.1-dev\n * Copyright (c) 2022-2024 Alain Dumesny - see GridStack root license\n */\n\nimport { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\n\nimport { AXGridLayoutContainerComponent } from './grid-layout-container.component';\nimport { AXGridLayoutWidgetComponent } from './grid-layout-widget.component';\n\n@NgModule({\n imports: [CommonModule],\n declarations: [AXGridLayoutContainerComponent, AXGridLayoutWidgetComponent],\n exports: [AXGridLayoutContainerComponent, AXGridLayoutWidgetComponent],\n})\nexport class AXGridLayoutBuilderModule {\n // constructor() {\n // set globally our method to create the right widget type\n // GridStack.addRemoveCB = gsCreateNgComponents;\n // GridStack.saveCB = gsSaveAdditionalNgInfo;\n // }\n}\n","import { AXGridLayoutContainerComponent } from './grid-layout-container.component';\nimport { AXGridLayoutWidgetComponent } from './grid-layout-widget.component';\n//TYPES\nexport type AXGridLayoutNode = import('gridstack').GridStackNode;\nexport type AXGridLayout = import('gridstack').GridStack;\nexport type AXGridLayoutOptions = import('gridstack').GridStackOptions;\nexport type AXGridLayoutWidget = import('gridstack').GridStackWidget & { data?: any };\nexport type AXGridLayoutContainerElement = import('gridstack').GridHTMLElement;\nexport type AXGridLayoutWidgetElement = import('gridstack').GridItemHTMLElement;\n//EVENTS\nexport type AXGridLayoutEventEvent = { event: Event };\nexport type AXGridLayoutElementEvent = { event: Event; el: AXGridLayoutWidgetElement };\nexport type AXGridLayoutNodesEvent = { event: Event; nodes: AXGridLayoutNode[] };\nexport type AXGridLayoutDroppedEvent = {\n event: Event;\n previousNode: AXGridLayoutNode;\n newNode: AXGridLayoutNode;\n};\n//COMPONENTS\nexport interface AXGridLayoutContainerCompElement extends AXGridLayoutContainerElement {\n _gridComp?: AXGridLayoutContainerComponent;\n}\nexport interface AXGridLayoutWidgetCompElement extends AXGridLayoutWidgetElement {\n _gridWidgetComp?: AXGridLayoutWidgetComponent;\n}\n\n//Callback\nexport type AXSaveCallback = import('gridstack').SaveFcn;\n\n// //DYNAMIC\n// export type AXNgCompInputs = { [key: string]: any };\n// export type SelectorToType = { [key: string]: Type<object> }; // selector string to runtime Type mapping\n// export interface AXNgGridLayoutWidget extends AXGridLayoutWidget {\n// selector?: string; //Angular tag selector for this component to create at runtime\n// input?: AXNgCompInputs; // serialized data for the component input fields\n// subGridOpts?: AXNgGridLayoutOptions; // nested grid options\n// }\n// export interface AXNgGridLayoutNode extends AXGridLayoutNode {\n// selector?: string; // component type to create as content\n// }\n// export interface AXNgGridLayoutOptions extends AXGridLayoutOptions {\n// children?: AXNgGridLayoutWidget[];\n// subGridOpts?: AXNgGridLayoutOptions;\n// }\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;AAUA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