@acorex/components 21.0.0-next.12 → 21.0.0-next.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/fesm2022/acorex-components-tree2.mjs +204 -111
 - package/fesm2022/acorex-components-tree2.mjs.map +1 -1
 - package/package.json +11 -11
 - package/tree2/index.d.ts +82 -11
 
    
        package/package.json
    CHANGED
    
    | 
         @@ -1,9 +1,9 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            {
         
     | 
| 
       2 
2 
     | 
    
         
             
              "name": "@acorex/components",
         
     | 
| 
       3 
     | 
    
         
            -
              "version": "21.0.0-next. 
     | 
| 
      
 3 
     | 
    
         
            +
              "version": "21.0.0-next.13",
         
     | 
| 
       4 
4 
     | 
    
         
             
              "peerDependencies": {
         
     | 
| 
       5 
     | 
    
         
            -
                "@acorex/core": "21.0.0-next. 
     | 
| 
       6 
     | 
    
         
            -
                "@acorex/cdk": "21.0.0-next. 
     | 
| 
      
 5 
     | 
    
         
            +
                "@acorex/core": "21.0.0-next.13",
         
     | 
| 
      
 6 
     | 
    
         
            +
                "@acorex/cdk": "21.0.0-next.13",
         
     | 
| 
       7 
7 
     | 
    
         
             
                "@angular/common": "^20.0.0",
         
     | 
| 
       8 
8 
     | 
    
         
             
                "@angular/core": "^20.0.0",
         
     | 
| 
       9 
9 
     | 
    
         
             
                "@angular/cdk": "^20.0.0",
         
     | 
| 
         @@ -68,14 +68,14 @@ 
     | 
|
| 
       68 
68 
     | 
    
         
             
                  "types": "./accordion/index.d.ts",
         
     | 
| 
       69 
69 
     | 
    
         
             
                  "default": "./fesm2022/acorex-components-accordion.mjs"
         
     | 
| 
       70 
70 
     | 
    
         
             
                },
         
     | 
| 
       71 
     | 
    
         
            -
                "./action-sheet": {
         
     | 
| 
       72 
     | 
    
         
            -
                  "types": "./action-sheet/index.d.ts",
         
     | 
| 
       73 
     | 
    
         
            -
                  "default": "./fesm2022/acorex-components-action-sheet.mjs"
         
     | 
| 
       74 
     | 
    
         
            -
                },
         
     | 
| 
       75 
71 
     | 
    
         
             
                "./alert": {
         
     | 
| 
       76 
72 
     | 
    
         
             
                  "types": "./alert/index.d.ts",
         
     | 
| 
       77 
73 
     | 
    
         
             
                  "default": "./fesm2022/acorex-components-alert.mjs"
         
     | 
| 
       78 
74 
     | 
    
         
             
                },
         
     | 
| 
      
 75 
     | 
    
         
            +
                "./action-sheet": {
         
     | 
| 
      
 76 
     | 
    
         
            +
                  "types": "./action-sheet/index.d.ts",
         
     | 
| 
      
 77 
     | 
    
         
            +
                  "default": "./fesm2022/acorex-components-action-sheet.mjs"
         
     | 
| 
      
 78 
     | 
    
         
            +
                },
         
     | 
| 
       79 
79 
     | 
    
         
             
                "./aspect-ratio": {
         
     | 
| 
       80 
80 
     | 
    
         
             
                  "types": "./aspect-ratio/index.d.ts",
         
     | 
| 
       81 
81 
     | 
    
         
             
                  "default": "./fesm2022/acorex-components-aspect-ratio.mjs"
         
     | 
| 
         @@ -324,6 +324,10 @@ 
     | 
|
| 
       324 
324 
     | 
    
         
             
                  "types": "./picker/index.d.ts",
         
     | 
| 
       325 
325 
     | 
    
         
             
                  "default": "./fesm2022/acorex-components-picker.mjs"
         
     | 
| 
       326 
326 
     | 
    
         
             
                },
         
     | 
| 
      
 327 
     | 
    
         
            +
                "./popover": {
         
     | 
| 
      
 328 
     | 
    
         
            +
                  "types": "./popover/index.d.ts",
         
     | 
| 
      
 329 
     | 
    
         
            +
                  "default": "./fesm2022/acorex-components-popover.mjs"
         
     | 
| 
      
 330 
     | 
    
         
            +
                },
         
     | 
| 
       327 
331 
     | 
    
         
             
                "./popup": {
         
     | 
| 
       328 
332 
     | 
    
         
             
                  "types": "./popup/index.d.ts",
         
     | 
| 
       329 
333 
     | 
    
         
             
                  "default": "./fesm2022/acorex-components-popup.mjs"
         
     | 
| 
         @@ -332,10 +336,6 @@ 
     | 
|
| 
       332 
336 
     | 
    
         
             
                  "types": "./progress-bar/index.d.ts",
         
     | 
| 
       333 
337 
     | 
    
         
             
                  "default": "./fesm2022/acorex-components-progress-bar.mjs"
         
     | 
| 
       334 
338 
     | 
    
         
             
                },
         
     | 
| 
       335 
     | 
    
         
            -
                "./popover": {
         
     | 
| 
       336 
     | 
    
         
            -
                  "types": "./popover/index.d.ts",
         
     | 
| 
       337 
     | 
    
         
            -
                  "default": "./fesm2022/acorex-components-popover.mjs"
         
     | 
| 
       338 
     | 
    
         
            -
                },
         
     | 
| 
       339 
339 
     | 
    
         
             
                "./qrcode": {
         
     | 
| 
       340 
340 
     | 
    
         
             
                  "types": "./qrcode/index.d.ts",
         
     | 
| 
       341 
341 
     | 
    
         
             
                  "default": "./fesm2022/acorex-components-qrcode.mjs"
         
     | 
    
        package/tree2/index.d.ts
    CHANGED
    
    | 
         @@ -57,7 +57,7 @@ import * as i1 from '@angular/common'; 
     | 
|
| 
       57 
57 
     | 
    
         
             
             * All color tokens use Acorex design system variables (`--ax-sys-color-*`) for automatic
         
     | 
| 
       58 
58 
     | 
    
         
             
             * light/dark mode support. Colors adapt based on the active theme without additional configuration.
         
     | 
| 
       59 
59 
     | 
    
         
             
             */
         
     | 
| 
       60 
     | 
    
         
            -
            interface  
     | 
| 
      
 60 
     | 
    
         
            +
            interface AXTreeBeforeDropEvent extends AXEvent {
         
     | 
| 
       61 
61 
     | 
    
         
             
                movedNode: AXTreeNode;
         
     | 
| 
       62 
62 
     | 
    
         
             
                previousParent?: AXTreeNode;
         
     | 
| 
       63 
63 
     | 
    
         
             
                currentParent?: AXTreeNode;
         
     | 
| 
         @@ -79,7 +79,10 @@ interface AXTreeNode { 
     | 
|
| 
       79 
79 
     | 
    
         
             
                loading?: boolean;
         
     | 
| 
       80 
80 
     | 
    
         
             
                data?: unknown;
         
     | 
| 
       81 
81 
     | 
    
         
             
            }
         
     | 
| 
       82 
     | 
    
         
            -
            interface  
     | 
| 
      
 82 
     | 
    
         
            +
            interface AXTreeNodeToggleEvent extends AXHtmlEvent {
         
     | 
| 
      
 83 
     | 
    
         
            +
                node: AXTreeNode;
         
     | 
| 
      
 84 
     | 
    
         
            +
            }
         
     | 
| 
      
 85 
     | 
    
         
            +
            interface AXTreeNodeSelectEvent extends AXHtmlEvent {
         
     | 
| 
       83 
86 
     | 
    
         
             
                node: AXTreeNode;
         
     | 
| 
       84 
87 
     | 
    
         
             
            }
         
     | 
| 
       85 
88 
     | 
    
         
             
            interface AXTreeDropEvent extends AXEvent {
         
     | 
| 
         @@ -99,21 +102,25 @@ interface AXTreeItemTemplateContext { 
     | 
|
| 
       99 
102 
     | 
    
         
             
            }
         
     | 
| 
       100 
103 
     | 
    
         
             
            type AXTreeViewLook = 'default' | 'card' | 'with-line';
         
     | 
| 
       101 
104 
     | 
    
         
             
            type AXTreeDragMode = 'none' | 'handler' | 'item';
         
     | 
| 
      
 105 
     | 
    
         
            +
            type AXTreeDragOperationType = 'order-only' | 'move' | 'both';
         
     | 
| 
       102 
106 
     | 
    
         | 
| 
       103 
107 
     | 
    
         
             
            declare class AXTree2Component {
         
     | 
| 
       104 
108 
     | 
    
         
             
                #private;
         
     | 
| 
      
 109 
     | 
    
         
            +
                private readonly ROOT_LIST_ID;
         
     | 
| 
      
 110 
     | 
    
         
            +
                private readonly NODE_DROP_PREFIX;
         
     | 
| 
      
 111 
     | 
    
         
            +
                private readonly LIST_PREFIX;
         
     | 
| 
       105 
112 
     | 
    
         
             
                /** Tree data nodes */
         
     | 
| 
       106 
113 
     | 
    
         
             
                nodes: _angular_core.ModelSignal<AXTreeNode[]>;
         
     | 
| 
       107 
114 
     | 
    
         
             
                /** Whether to show checkboxes for selection */
         
     | 
| 
       108 
115 
     | 
    
         
             
                showCheckbox: _angular_core.InputSignal<boolean>;
         
     | 
| 
       109 
116 
     | 
    
         
             
                /** Drag and drop mode: 'none' (disabled), 'handler' (drag handle), 'item' (entire item) */
         
     | 
| 
       110 
117 
     | 
    
         
             
                dragMode: _angular_core.InputSignal<AXTreeDragMode>;
         
     | 
| 
      
 118 
     | 
    
         
            +
                /** Drag operation type: 'order-only' (reorder only), 'move' (move between parents), 'both' (allow both) */
         
     | 
| 
      
 119 
     | 
    
         
            +
                dragOperationType: _angular_core.InputSignal<AXTreeDragOperationType>;
         
     | 
| 
       111 
120 
     | 
    
         
             
                /** Whether to show icons */
         
     | 
| 
       112 
121 
     | 
    
         
             
                showIcons: _angular_core.InputSignal<boolean>;
         
     | 
| 
       113 
122 
     | 
    
         
             
                /** Whether to show children count badge */
         
     | 
| 
       114 
123 
     | 
    
         
             
                showChildrenBadge: _angular_core.InputSignal<boolean>;
         
     | 
| 
       115 
     | 
    
         
            -
                /** Whether to animate expand/collapse */
         
     | 
| 
       116 
     | 
    
         
            -
                animated: _angular_core.InputSignal<boolean>;
         
     | 
| 
       117 
124 
     | 
    
         
             
                /** Custom icon for expanded nodes */
         
     | 
| 
       118 
125 
     | 
    
         
             
                expandedIcon: _angular_core.InputSignal<string>;
         
     | 
| 
       119 
126 
     | 
    
         
             
                /** Custom icon for collapsed nodes */
         
     | 
| 
         @@ -131,13 +138,17 @@ declare class AXTree2Component { 
     | 
|
| 
       131 
138 
     | 
    
         
             
                /** Whether to enable lazy loading */
         
     | 
| 
       132 
139 
     | 
    
         
             
                enableLazyLoad: _angular_core.InputSignal<boolean>;
         
     | 
| 
       133 
140 
     | 
    
         
             
                /** Emitted before a drop operation - set canceled to true to prevent drop */
         
     | 
| 
       134 
     | 
    
         
            -
                onBeforeDrop: _angular_core.OutputEmitterRef< 
     | 
| 
      
 141 
     | 
    
         
            +
                onBeforeDrop: _angular_core.OutputEmitterRef<AXTreeBeforeDropEvent>;
         
     | 
| 
       135 
142 
     | 
    
         
             
                /** Emitted when a node is toggled (expanded/collapsed) */
         
     | 
| 
       136 
     | 
    
         
            -
                 
     | 
| 
      
 143 
     | 
    
         
            +
                onNodeToggle: _angular_core.OutputEmitterRef<AXTreeNodeToggleEvent>;
         
     | 
| 
       137 
144 
     | 
    
         
             
                /** Emitted when a node is selected/deselected */
         
     | 
| 
       138 
     | 
    
         
            -
                 
     | 
| 
       139 
     | 
    
         
            -
                /** Emitted when  
     | 
| 
       140 
     | 
    
         
            -
                 
     | 
| 
      
 145 
     | 
    
         
            +
                onNodeSelect: _angular_core.OutputEmitterRef<AXTreeNodeSelectEvent>;
         
     | 
| 
      
 146 
     | 
    
         
            +
                /** Emitted when nodes are reordered within the same parent */
         
     | 
| 
      
 147 
     | 
    
         
            +
                onOrderChange: _angular_core.OutputEmitterRef<AXTreeDropEvent>;
         
     | 
| 
      
 148 
     | 
    
         
            +
                /** Emitted when a node is moved to a different parent */
         
     | 
| 
      
 149 
     | 
    
         
            +
                onMoveChange: _angular_core.OutputEmitterRef<AXTreeDropEvent>;
         
     | 
| 
      
 150 
     | 
    
         
            +
                /** Emitted for any item change (order or move) */
         
     | 
| 
      
 151 
     | 
    
         
            +
                onItemsChange: _angular_core.OutputEmitterRef<AXTreeDropEvent>;
         
     | 
| 
       141 
152 
     | 
    
         
             
                /** Internal signal for tracking loading state */
         
     | 
| 
       142 
153 
     | 
    
         
             
                protected readonly loadingNodes: _angular_core.WritableSignal<Set<string>>;
         
     | 
| 
       143 
154 
     | 
    
         
             
                /**
         
     | 
| 
         @@ -217,6 +228,10 @@ declare class AXTree2Component { 
     | 
|
| 
       217 
228 
     | 
    
         
             
                 * Get count of selected nodes
         
     | 
| 
       218 
229 
     | 
    
         
             
                 */
         
     | 
| 
       219 
230 
     | 
    
         
             
                getSelectedCount(): number;
         
     | 
| 
      
 231 
     | 
    
         
            +
                /**
         
     | 
| 
      
 232 
     | 
    
         
            +
                 * Check if any nodes are selected
         
     | 
| 
      
 233 
     | 
    
         
            +
                 */
         
     | 
| 
      
 234 
     | 
    
         
            +
                hasSelection(): boolean;
         
     | 
| 
       220 
235 
     | 
    
         
             
                /**
         
     | 
| 
       221 
236 
     | 
    
         
             
                 * Recursively count selected nodes
         
     | 
| 
       222 
237 
     | 
    
         
             
                 */
         
     | 
| 
         @@ -233,6 +248,26 @@ declare class AXTree2Component { 
     | 
|
| 
       233 
248 
     | 
    
         
             
                 * Delete selected nodes from the tree
         
     | 
| 
       234 
249 
     | 
    
         
             
                 */
         
     | 
| 
       235 
250 
     | 
    
         
             
                deleteSelected(): void;
         
     | 
| 
      
 251 
     | 
    
         
            +
                /**
         
     | 
| 
      
 252 
     | 
    
         
            +
                 * Select all nodes in the tree
         
     | 
| 
      
 253 
     | 
    
         
            +
                 */
         
     | 
| 
      
 254 
     | 
    
         
            +
                selectAll(): void;
         
     | 
| 
      
 255 
     | 
    
         
            +
                /**
         
     | 
| 
      
 256 
     | 
    
         
            +
                 * Deselect all nodes in the tree
         
     | 
| 
      
 257 
     | 
    
         
            +
                 */
         
     | 
| 
      
 258 
     | 
    
         
            +
                deselectAll(): void;
         
     | 
| 
      
 259 
     | 
    
         
            +
                /**
         
     | 
| 
      
 260 
     | 
    
         
            +
                 * Find a node by ID in the tree
         
     | 
| 
      
 261 
     | 
    
         
            +
                 */
         
     | 
| 
      
 262 
     | 
    
         
            +
                findNode(id: string): AXTreeNode | null;
         
     | 
| 
      
 263 
     | 
    
         
            +
                /**
         
     | 
| 
      
 264 
     | 
    
         
            +
                 * Refresh the tree to trigger change detection
         
     | 
| 
      
 265 
     | 
    
         
            +
                 */
         
     | 
| 
      
 266 
     | 
    
         
            +
                refresh(): void;
         
     | 
| 
      
 267 
     | 
    
         
            +
                /**
         
     | 
| 
      
 268 
     | 
    
         
            +
                 * Recursively set selection state for all nodes
         
     | 
| 
      
 269 
     | 
    
         
            +
                 */
         
     | 
| 
      
 270 
     | 
    
         
            +
                private setAllSelection;
         
     | 
| 
       236 
271 
     | 
    
         
             
                /**
         
     | 
| 
       237 
272 
     | 
    
         
             
                 * Recursively remove selected nodes
         
     | 
| 
       238 
273 
     | 
    
         
             
                 */
         
     | 
| 
         @@ -253,8 +288,44 @@ declare class AXTree2Component { 
     | 
|
| 
       253 
288 
     | 
    
         
             
                 * Check if node should show expand toggle
         
     | 
| 
       254 
289 
     | 
    
         
             
                 */
         
     | 
| 
       255 
290 
     | 
    
         
             
                shouldShowExpandToggle(node: AXTreeNode): boolean;
         
     | 
| 
      
 291 
     | 
    
         
            +
                /**
         
     | 
| 
      
 292 
     | 
    
         
            +
                 * Check if node has children
         
     | 
| 
      
 293 
     | 
    
         
            +
                 */
         
     | 
| 
      
 294 
     | 
    
         
            +
                private hasChildren;
         
     | 
| 
      
 295 
     | 
    
         
            +
                /**
         
     | 
| 
      
 296 
     | 
    
         
            +
                 * Check if node can be lazy loaded
         
     | 
| 
      
 297 
     | 
    
         
            +
                 */
         
     | 
| 
      
 298 
     | 
    
         
            +
                private canLazyLoad;
         
     | 
| 
      
 299 
     | 
    
         
            +
                /**
         
     | 
| 
      
 300 
     | 
    
         
            +
                 * Check if move operation is allowed based on dragOperationType
         
     | 
| 
      
 301 
     | 
    
         
            +
                 */
         
     | 
| 
      
 302 
     | 
    
         
            +
                private canMoveToParent;
         
     | 
| 
      
 303 
     | 
    
         
            +
                /**
         
     | 
| 
      
 304 
     | 
    
         
            +
                 * Check if reorder operation is allowed based on dragOperationType
         
     | 
| 
      
 305 
     | 
    
         
            +
                 */
         
     | 
| 
      
 306 
     | 
    
         
            +
                private canReorder;
         
     | 
| 
      
 307 
     | 
    
         
            +
                /**
         
     | 
| 
      
 308 
     | 
    
         
            +
                 * Validate if drop target is valid (prevent circular references)
         
     | 
| 
      
 309 
     | 
    
         
            +
                 */
         
     | 
| 
      
 310 
     | 
    
         
            +
                private isValidDropTarget;
         
     | 
| 
      
 311 
     | 
    
         
            +
                /**
         
     | 
| 
      
 312 
     | 
    
         
            +
                 * Handle reordering within the same list
         
     | 
| 
      
 313 
     | 
    
         
            +
                 */
         
     | 
| 
      
 314 
     | 
    
         
            +
                private handleReorder;
         
     | 
| 
      
 315 
     | 
    
         
            +
                /**
         
     | 
| 
      
 316 
     | 
    
         
            +
                 * Handle moving between different lists
         
     | 
| 
      
 317 
     | 
    
         
            +
                 */
         
     | 
| 
      
 318 
     | 
    
         
            +
                private handleMove;
         
     | 
| 
      
 319 
     | 
    
         
            +
                /**
         
     | 
| 
      
 320 
     | 
    
         
            +
                 * Emit beforeDrop event and return whether to continue
         
     | 
| 
      
 321 
     | 
    
         
            +
                 */
         
     | 
| 
      
 322 
     | 
    
         
            +
                private emitBeforeDropEvent;
         
     | 
| 
      
 323 
     | 
    
         
            +
                /**
         
     | 
| 
      
 324 
     | 
    
         
            +
                 * Emit drop events based on operation type
         
     | 
| 
      
 325 
     | 
    
         
            +
                 */
         
     | 
| 
      
 326 
     | 
    
         
            +
                private emitDropEvents;
         
     | 
| 
       256 
327 
     | 
    
         
             
                static ɵfac: _angular_core.ɵɵFactoryDeclaration<AXTree2Component, never>;
         
     | 
| 
       257 
     | 
    
         
            -
                static ɵcmp: _angular_core.ɵɵComponentDeclaration<AXTree2Component, "ax-tree2", never, { "nodes": { "alias": "nodes"; "required": true; "isSignal": true; }; "showCheckbox": { "alias": "showCheckbox"; "required": false; "isSignal": true; }; "dragMode": { "alias": "dragMode"; "required": false; "isSignal": true; }; " 
     | 
| 
      
 328 
     | 
    
         
            +
                static ɵcmp: _angular_core.ɵɵComponentDeclaration<AXTree2Component, "ax-tree2", never, { "nodes": { "alias": "nodes"; "required": true; "isSignal": true; }; "showCheckbox": { "alias": "showCheckbox"; "required": false; "isSignal": true; }; "dragMode": { "alias": "dragMode"; "required": false; "isSignal": true; }; "dragOperationType": { "alias": "dragOperationType"; "required": false; "isSignal": true; }; "showIcons": { "alias": "showIcons"; "required": false; "isSignal": true; }; "showChildrenBadge": { "alias": "showChildrenBadge"; "required": false; "isSignal": true; }; "expandedIcon": { "alias": "expandedIcon"; "required": false; "isSignal": true; }; "collapsedIcon": { "alias": "collapsedIcon"; "required": false; "isSignal": true; }; "indentSize": { "alias": "indentSize"; "required": false; "isSignal": true; }; "nodeHeight": { "alias": "nodeHeight"; "required": false; "isSignal": true; }; "look": { "alias": "look"; "required": false; "isSignal": true; }; "itemTemplate": { "alias": "itemTemplate"; "required": false; "isSignal": true; }; "lazyLoad": { "alias": "lazyLoad"; "required": false; "isSignal": true; }; "enableLazyLoad": { "alias": "enableLazyLoad"; "required": false; "isSignal": true; }; }, { "nodes": "nodesChange"; "onBeforeDrop": "onBeforeDrop"; "onNodeToggle": "onNodeToggle"; "onNodeSelect": "onNodeSelect"; "onOrderChange": "onOrderChange"; "onMoveChange": "onMoveChange"; "onItemsChange": "onItemsChange"; }, never, never, true, never>;
         
     | 
| 
       258 
329 
     | 
    
         
             
            }
         
     | 
| 
       259 
330 
     | 
    
         | 
| 
       260 
331 
     | 
    
         
             
            declare class Tree2Module {
         
     | 
| 
         @@ -264,4 +335,4 @@ declare class Tree2Module { 
     | 
|
| 
       264 
335 
     | 
    
         
             
            }
         
     | 
| 
       265 
336 
     | 
    
         | 
| 
       266 
337 
     | 
    
         
             
            export { AXTree2Component, Tree2Module };
         
     | 
| 
       267 
     | 
    
         
            -
            export type { AXTreeDragMode, AXTreeDropEvent, AXTreeItemTemplateContext, AXTreeNode,  
     | 
| 
      
 338 
     | 
    
         
            +
            export type { AXTreeBeforeDropEvent, AXTreeDragMode, AXTreeDragOperationType, AXTreeDropEvent, AXTreeItemTemplateContext, AXTreeNode, AXTreeNodeSelectEvent, AXTreeNodeToggleEvent, AXTreeViewLook };
         
     |