@acorex/components 21.0.2-next.11 → 21.0.2-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-button-group.mjs +26 -6
- package/fesm2022/acorex-components-button-group.mjs.map +1 -1
- package/fesm2022/acorex-components-color-palette.mjs +50 -9
- package/fesm2022/acorex-components-color-palette.mjs.map +1 -1
- package/fesm2022/acorex-components-conversation2.mjs +84 -40
- package/fesm2022/acorex-components-conversation2.mjs.map +1 -1
- package/fesm2022/acorex-components-flow-chart.mjs +42 -25
- package/fesm2022/acorex-components-flow-chart.mjs.map +1 -1
- package/fesm2022/acorex-components-number-box.mjs +43 -5
- package/fesm2022/acorex-components-number-box.mjs.map +1 -1
- package/fesm2022/acorex-components-qrcode.mjs +19 -2
- package/fesm2022/acorex-components-qrcode.mjs.map +1 -1
- package/fesm2022/acorex-components-query-builder.mjs +3 -2
- package/fesm2022/acorex-components-query-builder.mjs.map +1 -1
- package/fesm2022/acorex-components-scheduler.mjs +1 -0
- package/fesm2022/acorex-components-scheduler.mjs.map +1 -1
- package/fesm2022/acorex-components-time-duration.mjs +3 -5
- package/fesm2022/acorex-components-time-duration.mjs.map +1 -1
- package/package.json +3 -3
- package/types/acorex-components-button-group.d.ts +9 -3
- package/types/acorex-components-color-palette.d.ts +2 -0
- package/types/acorex-components-flow-chart.d.ts +4 -0
- package/types/acorex-components-number-box.d.ts +9 -0
- package/types/acorex-components-qrcode.d.ts +1 -0
- package/types/acorex-components-query-builder.d.ts +1 -1
|
@@ -4,9 +4,9 @@ import { AXButtonModule } from '@acorex/components/button';
|
|
|
4
4
|
import * as i1 from '@acorex/components/text-box';
|
|
5
5
|
import { AXTextBoxModule } from '@acorex/components/text-box';
|
|
6
6
|
import * as i3 from '@angular/common';
|
|
7
|
-
import { CommonModule } from '@angular/common';
|
|
7
|
+
import { DOCUMENT, isPlatformBrowser, CommonModule } from '@angular/common';
|
|
8
8
|
import * as i0 from '@angular/core';
|
|
9
|
-
import { inject, NgZone, signal, effect, Injectable, ViewEncapsulation, ChangeDetectionStrategy, Component, viewChild, output, afterNextRender, input, computed, HostListener, NgModule } from '@angular/core';
|
|
9
|
+
import { inject, NgZone, PLATFORM_ID, signal, effect, Injectable, ViewEncapsulation, ChangeDetectionStrategy, Component, viewChild, output, afterNextRender, input, computed, HostListener, NgModule } from '@angular/core';
|
|
10
10
|
import * as i4 from '@angular/forms';
|
|
11
11
|
import { FormsModule } from '@angular/forms';
|
|
12
12
|
import { Subject } from 'rxjs';
|
|
@@ -14,6 +14,8 @@ import { Subject } from 'rxjs';
|
|
|
14
14
|
class AXFlowChartService {
|
|
15
15
|
constructor() {
|
|
16
16
|
this.zone = inject(NgZone);
|
|
17
|
+
this.platformId = inject(PLATFORM_ID);
|
|
18
|
+
this.document = inject(DOCUMENT);
|
|
17
19
|
this.initialFlowChartEdge = signal([], ...(ngDevMode ? [{ debugName: "initialFlowChartEdge" }] : []));
|
|
18
20
|
this.initialFlowChartNode = signal([], ...(ngDevMode ? [{ debugName: "initialFlowChartNode" }] : []));
|
|
19
21
|
this.selectedNode = signal(null, ...(ngDevMode ? [{ debugName: "selectedNode" }] : []));
|
|
@@ -33,16 +35,18 @@ class AXFlowChartService {
|
|
|
33
35
|
this.draggingConnection = false;
|
|
34
36
|
this.tempLine = null;
|
|
35
37
|
this.#eff2 = effect(() => {
|
|
36
|
-
if (this.initialFlowChartEdge()) {
|
|
37
|
-
|
|
38
|
-
this.drawEdges(this.initialFlowChartEdge());
|
|
39
|
-
});
|
|
38
|
+
if (!isPlatformBrowser(this.platformId) || !this.initialFlowChartEdge()) {
|
|
39
|
+
return;
|
|
40
40
|
}
|
|
41
|
+
setTimeout(() => {
|
|
42
|
+
this.drawEdges(this.initialFlowChartEdge());
|
|
43
|
+
});
|
|
41
44
|
}, ...(ngDevMode ? [{ debugName: "#eff2" }] : []));
|
|
42
45
|
this.#eff3 = effect(() => {
|
|
43
|
-
if (this.initialFlowChartNode()) {
|
|
44
|
-
|
|
46
|
+
if (!isPlatformBrowser(this.platformId) || !this.initialFlowChartNode()) {
|
|
47
|
+
return;
|
|
45
48
|
}
|
|
49
|
+
this.createNode(this.initialFlowChartNode());
|
|
46
50
|
}, ...(ngDevMode ? [{ debugName: "#eff3" }] : []));
|
|
47
51
|
}
|
|
48
52
|
#eff2;
|
|
@@ -143,7 +147,7 @@ class AXFlowChartService {
|
|
|
143
147
|
}
|
|
144
148
|
addAnchors(el, type) {
|
|
145
149
|
['top', 'bottom', 'left', 'right'].forEach((anchor) => {
|
|
146
|
-
const dot = document.createElement('div');
|
|
150
|
+
const dot = this.document.createElement('div');
|
|
147
151
|
dot.className = 'ax-flow-chart-anchor';
|
|
148
152
|
dot.dataset['anchor'] = anchor;
|
|
149
153
|
dot.dataset['nodeId'] = el.dataset['id'];
|
|
@@ -205,8 +209,8 @@ class AXFlowChartService {
|
|
|
205
209
|
};
|
|
206
210
|
// Add global event listeners
|
|
207
211
|
this.zone.runOutsideAngular(() => {
|
|
208
|
-
document.addEventListener('mousemove', mousemoveHandler);
|
|
209
|
-
document.addEventListener('mouseup', mouseupHandler);
|
|
212
|
+
this.document.addEventListener('mousemove', mousemoveHandler);
|
|
213
|
+
this.document.addEventListener('mouseup', mouseupHandler);
|
|
210
214
|
});
|
|
211
215
|
// Store global listeners
|
|
212
216
|
const globalListeners = this.eventListeners.get('global');
|
|
@@ -278,7 +282,7 @@ class AXFlowChartService {
|
|
|
278
282
|
const svgElement = this.svgService()?.nativeElement;
|
|
279
283
|
if (!svgElement)
|
|
280
284
|
return;
|
|
281
|
-
this.tempLine = document.createElementNS('http://www.w3.org/2000/svg', 'line');
|
|
285
|
+
this.tempLine = this.document.createElementNS('http://www.w3.org/2000/svg', 'line');
|
|
282
286
|
this.tempLine.setAttribute('x1', x.toString());
|
|
283
287
|
this.tempLine.setAttribute('y1', y.toString());
|
|
284
288
|
this.tempLine.setAttribute('x2', x.toString());
|
|
@@ -305,6 +309,9 @@ class AXFlowChartService {
|
|
|
305
309
|
this.drawEdges();
|
|
306
310
|
}
|
|
307
311
|
drawEdges(edges) {
|
|
312
|
+
if (!isPlatformBrowser(this.platformId)) {
|
|
313
|
+
return;
|
|
314
|
+
}
|
|
308
315
|
const svg = this.svgService()?.nativeElement;
|
|
309
316
|
if (!svg)
|
|
310
317
|
return;
|
|
@@ -337,7 +344,7 @@ class AXFlowChartService {
|
|
|
337
344
|
this.selectedEdge.set(edge);
|
|
338
345
|
this.selectedNode.set(null);
|
|
339
346
|
// Remove selection from all other lines
|
|
340
|
-
document.querySelectorAll('.ax-flow-chart-line').forEach((l) => {
|
|
347
|
+
this.document.querySelectorAll('.ax-flow-chart-line').forEach((l) => {
|
|
341
348
|
if (l !== line)
|
|
342
349
|
l.classList.remove('selected');
|
|
343
350
|
});
|
|
@@ -351,7 +358,7 @@ class AXFlowChartService {
|
|
|
351
358
|
});
|
|
352
359
|
}
|
|
353
360
|
createLine(from, to, edge) {
|
|
354
|
-
const line = document.createElementNS('http://www.w3.org/2000/svg', 'line');
|
|
361
|
+
const line = this.document.createElementNS('http://www.w3.org/2000/svg', 'line');
|
|
355
362
|
line.setAttribute('x1', from.x.toString());
|
|
356
363
|
line.setAttribute('y1', from.y.toString());
|
|
357
364
|
line.setAttribute('x2', to.x.toString());
|
|
@@ -391,10 +398,17 @@ class AXFlowChartService {
|
|
|
391
398
|
}
|
|
392
399
|
}
|
|
393
400
|
createNode(nodes) {
|
|
394
|
-
|
|
401
|
+
if (!isPlatformBrowser(this.platformId)) {
|
|
402
|
+
return;
|
|
403
|
+
}
|
|
404
|
+
const canvas = this.canvasService()?.nativeElement;
|
|
405
|
+
if (!canvas) {
|
|
406
|
+
return;
|
|
407
|
+
}
|
|
408
|
+
this.document.querySelectorAll('.ax-flow-chart-node')?.forEach((node) => node.remove());
|
|
395
409
|
nodes.forEach((node) => {
|
|
396
|
-
const el = document.createElement('div');
|
|
397
|
-
const p = document.createElement('p');
|
|
410
|
+
const el = this.document.createElement('div');
|
|
411
|
+
const p = this.document.createElement('p');
|
|
398
412
|
p.innerText = node.label;
|
|
399
413
|
el.appendChild(p);
|
|
400
414
|
el.className = 'ax-flow-chart-node';
|
|
@@ -405,7 +419,7 @@ class AXFlowChartService {
|
|
|
405
419
|
this.addAnchors(el, node.type);
|
|
406
420
|
this.makeDraggable(el);
|
|
407
421
|
this.setupNodeEventListeners(el, node);
|
|
408
|
-
|
|
422
|
+
canvas.appendChild(el);
|
|
409
423
|
this.nodesMap.set(node.id, el);
|
|
410
424
|
});
|
|
411
425
|
}
|
|
@@ -416,7 +430,7 @@ class AXFlowChartService {
|
|
|
416
430
|
this.removeEdge(edge);
|
|
417
431
|
}
|
|
418
432
|
});
|
|
419
|
-
document.querySelector(`[data-id="${nodeId}"]`)?.remove();
|
|
433
|
+
this.document.querySelector(`[data-id="${nodeId}"]`)?.remove();
|
|
420
434
|
this.anchorClickBuffer = null;
|
|
421
435
|
}
|
|
422
436
|
cleanup() {
|
|
@@ -513,6 +527,8 @@ class AXFlowChartRendererComponent extends NXComponent {
|
|
|
513
527
|
this.canvas = viewChild('canvas', ...(ngDevMode ? [{ debugName: "canvas" }] : []));
|
|
514
528
|
this.svg = viewChild('connections', ...(ngDevMode ? [{ debugName: "svg" }] : []));
|
|
515
529
|
this.service = inject(AXFlowChartService);
|
|
530
|
+
this.document = inject(DOCUMENT);
|
|
531
|
+
this.platformId = inject(PLATFORM_ID);
|
|
516
532
|
this.onLineClick = output();
|
|
517
533
|
this.onLineDbClick = output();
|
|
518
534
|
this.onNodeClick = output();
|
|
@@ -523,9 +539,10 @@ class AXFlowChartRendererComponent extends NXComponent {
|
|
|
523
539
|
this.setupEventListeners();
|
|
524
540
|
});
|
|
525
541
|
this.#eff = effect(() => {
|
|
526
|
-
if (this.canvas()
|
|
527
|
-
|
|
542
|
+
if (!isPlatformBrowser(this.platformId) || !this.canvas() || !this.svg()) {
|
|
543
|
+
return;
|
|
528
544
|
}
|
|
545
|
+
this.initializeServices();
|
|
529
546
|
}, ...(ngDevMode ? [{ debugName: "#eff" }] : []));
|
|
530
547
|
}
|
|
531
548
|
#init;
|
|
@@ -561,8 +578,8 @@ class AXFlowChartRendererComponent extends NXComponent {
|
|
|
561
578
|
if (e.target === canvas) {
|
|
562
579
|
this.service.selectedNode.set(null);
|
|
563
580
|
this.service.selectedEdge.set(null);
|
|
564
|
-
document.querySelectorAll('.ax-flow-chart-node').forEach((node) => node.classList.remove('selected'));
|
|
565
|
-
document.querySelectorAll('.ax-flow-chart-line').forEach((line) => line.classList.remove('selected'));
|
|
581
|
+
this.document.querySelectorAll('.ax-flow-chart-node').forEach((node) => node.classList.remove('selected'));
|
|
582
|
+
this.document.querySelectorAll('.ax-flow-chart-line').forEach((line) => line.classList.remove('selected'));
|
|
566
583
|
}
|
|
567
584
|
});
|
|
568
585
|
}
|
|
@@ -571,8 +588,8 @@ class AXFlowChartRendererComponent extends NXComponent {
|
|
|
571
588
|
if (e.target === svg) {
|
|
572
589
|
this.service.selectedNode.set(null);
|
|
573
590
|
this.service.selectedEdge.set(null);
|
|
574
|
-
document.querySelectorAll('.ax-flow-chart-node').forEach((node) => node.classList.remove('selected'));
|
|
575
|
-
document.querySelectorAll('.ax-flow-chart-line').forEach((line) => line.classList.remove('selected'));
|
|
591
|
+
this.document.querySelectorAll('.ax-flow-chart-node').forEach((node) => node.classList.remove('selected'));
|
|
592
|
+
this.document.querySelectorAll('.ax-flow-chart-line').forEach((line) => line.classList.remove('selected'));
|
|
576
593
|
}
|
|
577
594
|
});
|
|
578
595
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"acorex-components-flow-chart.mjs","sources":["../../../../packages/components/flow-chart/src/lib/flow-chart.service.ts","../../../../packages/components/flow-chart/src/lib/flow-chart-creator/flow-chart-creator.component.ts","../../../../packages/components/flow-chart/src/lib/flow-chart-creator/flow-chart-creator.component.html","../../../../packages/components/flow-chart/src/lib/flow-chart-renderer/flow-chart-renderer.component.ts","../../../../packages/components/flow-chart/src/lib/flow-chart-renderer/flow-chart-renderer.component.html","../../../../packages/components/flow-chart/src/lib/flow-chart.component.ts","../../../../packages/components/flow-chart/src/lib/flow-chart.component.html","../../../../packages/components/flow-chart/src/lib/flow-chart.module.ts","../../../../packages/components/flow-chart/src/acorex-components-flow-chart.ts"],"sourcesContent":["import { effect, inject, Injectable, NgZone, signal } from '@angular/core';\nimport { Subject } from 'rxjs';\nimport {\n AXFlowChartEdges,\n AXFlowChartNodes,\n AXLineClickEvent,\n AXNodeClickEvent,\n HTMLElementWithDataset,\n} from './flow-chart.type';\n\n@Injectable()\nexport class AXFlowChartService {\n private zone = inject(NgZone);\n\n initialFlowChartEdge = signal([]);\n initialFlowChartNode = signal([]);\n selectedNode = signal<AXFlowChartNodes | null>(null);\n selectedEdge = signal<AXFlowChartEdges | null>(null);\n readonly svgService = signal(null);\n readonly canvasService = signal(null);\n\n readonly lineClick = new Subject<AXLineClickEvent>();\n readonly lineDbClick = new Subject<AXLineClickEvent>();\n readonly nodeClick = new Subject<AXNodeClickEvent>();\n readonly nodeDbClick = new Subject<AXNodeClickEvent>();\n readonly onEdgeUpdate = new Subject<AXFlowChartEdges>();\n readonly onNodeUpdate = new Subject<AXFlowChartNodes>();\n\n private nodesMap = new Map<string, HTMLElementWithDataset>();\n private eventListeners = new Map<string, Map<string, EventListener>>();\n private anchorClickBuffer: { nodeId: string; anchor: string } | null = null;\n\n private currentConnection: {\n source?: { id: string; anchor: string };\n target?: { id: string; anchor: string };\n mouse?: { x: number; y: number };\n } | null = null;\n private draggingConnection = false;\n private tempLine: SVGLineElement | null = null;\n\n #eff2 = effect(() => {\n if (this.initialFlowChartEdge()) {\n setTimeout(() => {\n this.drawEdges(this.initialFlowChartEdge());\n });\n }\n });\n\n #eff3 = effect(() => {\n if (this.initialFlowChartNode()) {\n this.createNode(this.initialFlowChartNode());\n }\n });\n\n private addEventListener(element: HTMLElement, event: string, handler: EventListener) {\n const elementId = element.dataset['id'] || 'global';\n if (!this.eventListeners.has(elementId)) {\n this.eventListeners.set(elementId, new Map());\n }\n\n const elementListeners = this.eventListeners.get(elementId);\n if (elementListeners) {\n const boundHandler = handler.bind(this);\n elementListeners.set(event, boundHandler);\n element.addEventListener(event, boundHandler);\n }\n }\n\n private removeEventListeners(elementId: string) {\n const elementListeners = this.eventListeners.get(elementId);\n if (elementListeners) {\n elementListeners.forEach((handler, event) => {\n const element = this.nodesMap.get(elementId);\n if (element) {\n element.removeEventListener(event, handler);\n }\n });\n this.eventListeners.delete(elementId);\n }\n }\n\n private setupNodeEventListeners(\n el: HTMLElementWithDataset,\n node: { id: string; type: string; label: string; x: number; y: number },\n ) {\n this.addEventListener(el, 'click', (e: Event) => {\n this.nodeClick.next({ target: el, event: e as MouseEvent });\n this.selectedNode.set(node);\n el.classList.add('selected');\n this.nodesMap.forEach((existingNode) => {\n if (existingNode !== el) {\n existingNode.classList.remove('selected');\n }\n });\n });\n\n this.addEventListener(el, 'dblclick', (e: Event) => {\n this.nodeDbClick.next({ target: el, event: e as MouseEvent });\n });\n\n this.addEventListener(el, 'mouseenter', () => {\n el.classList.add('hover');\n });\n\n this.addEventListener(el, 'mouseleave', () => {\n el.classList.remove('hover');\n });\n }\n\n private setupAnchorEventListeners(dot: HTMLElementWithDataset, el: HTMLElementWithDataset) {\n // start drag to connect\n this.addEventListener(dot, 'mousedown', (e: Event) => {\n const mouseEvent = e as MouseEvent;\n mouseEvent.stopPropagation();\n mouseEvent.preventDefault();\n const pos = this.getAnchorPoint(el, dot.dataset['anchor']);\n\n this.currentConnection = {\n source: {\n id: dot.dataset['nodeId'],\n anchor: dot.dataset['anchor'],\n },\n mouse: { x: mouseEvent.clientX, y: mouseEvent.clientY },\n };\n\n this.startTempLine(pos.x, pos.y);\n this.draggingConnection = true;\n });\n\n this.addEventListener(dot, 'click', (e: Event) => {\n e.stopPropagation();\n\n if (dot.classList.contains('selected')) {\n dot.classList.remove('selected');\n } else {\n dot.classList.add('selected');\n }\n\n const clicked = {\n nodeId: dot.dataset['nodeId'],\n anchor: dot.dataset['anchor'],\n };\n\n console.log(clicked);\n\n if (!this.anchorClickBuffer) {\n this.anchorClickBuffer = clicked;\n } else {\n const source = this.anchorClickBuffer;\n const target = clicked;\n\n if (source.nodeId !== target.nodeId) {\n this.pushAndCreateEdgeData(\n { id: source.nodeId, anchor: source.anchor },\n { id: target.nodeId, anchor: target.anchor },\n );\n }\n\n this.anchorClickBuffer = null;\n }\n });\n\n this.addEventListener(dot, 'mouseenter', () => {\n dot.classList.add('hover');\n });\n\n this.addEventListener(dot, 'mouseleave', () => {\n dot.classList.remove('hover');\n });\n }\n\n private addAnchors(el: HTMLElementWithDataset, type: string) {\n ['top', 'bottom', 'left', 'right'].forEach((anchor) => {\n const dot = document.createElement('div') as HTMLElementWithDataset;\n dot.className = 'ax-flow-chart-anchor';\n dot.dataset['anchor'] = anchor;\n dot.dataset['nodeId'] = el.dataset['id'];\n\n this.positionAnchor(dot, anchor, type);\n el.appendChild(dot);\n\n this.setupAnchorEventListeners(dot, el);\n });\n }\n\n private makeDraggable(el: HTMLElement) {\n let offsetX = 0,\n offsetY = 0,\n isDragging = false;\n\n this.addEventListener(el, 'mousedown', (e: Event) => {\n const mouseEvent = e as MouseEvent;\n if ((mouseEvent.target as HTMLElement).classList.contains('ax-flow-chart-anchor')) return;\n isDragging = true;\n offsetX = mouseEvent.clientX - el.offsetLeft;\n offsetY = mouseEvent.clientY - el.offsetTop;\n mouseEvent.preventDefault();\n });\n\n const mousemoveHandler = (e: MouseEvent) => {\n if (isDragging) {\n el.style.left = e.clientX - offsetX + 'px';\n el.style.top = e.clientY - offsetY + 'px';\n this.drawEdges(this.initialFlowChartEdge());\n\n this.initialFlowChartNode.update((value) => {\n const node = value.find((node) => node.id === el.dataset['id']);\n if (node) {\n node.x = e.clientX - offsetX;\n node.y = e.clientY - offsetY;\n }\n return value;\n });\n }\n\n const elementId = (e.target as HTMLElement).id;\n if (elementId === 'ax-flow-chart-renderer-connections' || elementId === 'ax-flow-chart-renderer-canvas') {\n if (this.draggingConnection && this.tempLine) {\n this.tempLine.setAttribute('x2', e.offsetX.toString());\n this.tempLine.setAttribute('y2', e.offsetY.toString());\n }\n }\n };\n\n const mouseupHandler = (e: MouseEvent) => {\n isDragging = false;\n if (this.draggingConnection) {\n const target = (e.target as HTMLElement).closest('.ax-flow-chart-anchor') as HTMLElementWithDataset;\n if (target && target.dataset['nodeId'] !== this.currentConnection?.source?.id) {\n this.currentConnection = {\n ...this.currentConnection,\n target: {\n id: target.dataset['nodeId'],\n anchor: target.dataset['anchor'],\n },\n };\n this.finishConnection();\n }\n this.clearTempLine();\n this.draggingConnection = false;\n }\n };\n\n // Add global event listeners\n this.zone.runOutsideAngular(() => {\n document.addEventListener('mousemove', mousemoveHandler);\n document.addEventListener('mouseup', mouseupHandler);\n });\n\n // Store global listeners\n const globalListeners = this.eventListeners.get('global');\n if (globalListeners) {\n globalListeners.set('mousemove', mousemoveHandler as EventListener);\n globalListeners.set('mouseup', mouseupHandler as EventListener);\n }\n }\n\n private positionAnchor(dot: HTMLElement, anchor: string, type: string) {\n if (type !== 'diamond') {\n switch (anchor) {\n case 'top':\n dot.style.top = '0%';\n dot.style.left = '50%';\n break;\n case 'bottom':\n dot.style.top = '100%';\n dot.style.left = '50%';\n break;\n case 'left':\n dot.style.top = '50%';\n dot.style.left = '0%';\n break;\n case 'right':\n dot.style.top = '50%';\n dot.style.left = '100%';\n break;\n }\n } else {\n switch (anchor) {\n case 'top':\n dot.style.top = '0%';\n dot.style.left = '0%';\n break;\n case 'bottom':\n dot.style.top = '100%';\n dot.style.left = '100%';\n break;\n case 'left':\n dot.style.top = '100%';\n dot.style.left = '0%';\n break;\n case 'right':\n dot.style.top = '0%';\n dot.style.left = '100%';\n break;\n }\n }\n }\n\n private getAnchorPoint(el: HTMLElement, anchor: string): { x: number; y: number } {\n const rect = el.getBoundingClientRect();\n const centerX = el.offsetLeft + rect.width / 2;\n const centerY = el.offsetTop + rect.height / 2;\n\n switch (anchor) {\n case 'top':\n return { x: centerX, y: el.offsetTop };\n case 'bottom':\n return { x: centerX, y: el.offsetTop + rect.height };\n case 'left':\n return { x: el.offsetLeft, y: centerY };\n case 'right':\n return { x: el.offsetLeft + rect.width, y: centerY };\n default:\n return { x: centerX, y: centerY };\n }\n }\n\n private startTempLine(x: number, y: number) {\n const svgElement = this.svgService()?.nativeElement;\n\n if (!svgElement) return;\n\n this.tempLine = document.createElementNS('http://www.w3.org/2000/svg', 'line');\n this.tempLine.setAttribute('x1', x.toString());\n this.tempLine.setAttribute('y1', y.toString());\n this.tempLine.setAttribute('x2', x.toString());\n this.tempLine.setAttribute('y2', y.toString());\n this.tempLine.setAttribute('stroke', 'rgba(var(--ax-sys-color-on-lightest-surface),0.5)');\n this.tempLine.setAttribute('stroke-width', '2');\n this.tempLine.setAttribute('stroke-dasharray', '4');\n svgElement.appendChild(this.tempLine);\n }\n\n private clearTempLine() {\n if (this.tempLine && this.tempLine.parentElement) {\n this.svgService()?.nativeElement.removeChild(this.tempLine);\n this.tempLine = null;\n }\n }\n\n private pushAndCreateEdgeData(source: { id: string; anchor: string }, target: { id: string; anchor: string }) {\n const newEdge = {\n id: `edge-${Math.random().toString()}`,\n source,\n target,\n };\n\n this.onEdgeUpdate.next(newEdge);\n this.initialFlowChartEdge.update((value) => [...value, newEdge]);\n this.drawEdges();\n }\n\n drawEdges(edges?: AXFlowChartEdges[]) {\n const svg = this.svgService()?.nativeElement;\n if (!svg) return;\n\n // Clear existing edges\n svg.innerHTML = '';\n\n // Use provided edges or get from signal\n const edgesToDraw = edges || this.initialFlowChartEdge();\n\n edgesToDraw.forEach((edge) => {\n const sourceNode = this.nodesMap.get(edge.source.id);\n const targetNode = this.nodesMap.get(edge.target.id);\n\n if (sourceNode) {\n const sourceAnchor = sourceNode.querySelector(`[data-anchor=\"${edge.source.anchor}\"]`);\n if (sourceAnchor) sourceAnchor.classList.add('selected');\n }\n if (targetNode) {\n const targetAnchor = targetNode.querySelector(`[data-anchor=\"${edge.target.anchor}\"]`);\n if (targetAnchor) targetAnchor.classList.add('selected');\n }\n\n if (sourceNode && targetNode) {\n const sourcePoint = this.getAnchorPoint(sourceNode, edge.source.anchor);\n const targetPoint = this.getAnchorPoint(targetNode, edge.target.anchor);\n\n const line = this.createLine(sourcePoint, targetPoint, edge);\n line.classList.add('ax-flow-chart-line');\n\n // Add click event listener for line selection\n this.addEventListener(line as unknown as HTMLElement, 'click', (e: Event) => {\n e.stopPropagation();\n this.lineClick.next({ target: edge, event: e as MouseEvent });\n this.selectedEdge.set(edge);\n this.selectedNode.set(null);\n // Remove selection from all other lines\n document.querySelectorAll('.ax-flow-chart-line').forEach((l) => {\n if (l !== line) l.classList.remove('selected');\n });\n // Add selection to clicked line\n line.classList.add('selected');\n // Remove selection from all nodes\n this.nodesMap.forEach((node) => node.classList.remove('selected'));\n });\n\n svg.appendChild(line);\n }\n });\n }\n\n createLine(from: { x: number; y: number }, to: { x: number; y: number }, edge: AXFlowChartEdges) {\n const line = document.createElementNS('http://www.w3.org/2000/svg', 'line');\n line.setAttribute('x1', from.x.toString());\n line.setAttribute('y1', from.y.toString());\n line.setAttribute('x2', to.x.toString());\n line.setAttribute('y2', to.y.toString());\n line.setAttribute('stroke', 'rgba(var(--ax-sys-color-on-surface))');\n line.setAttribute('stroke-width', '3');\n line.classList.add('ax-flow-chart-line');\n line.addEventListener('click', (e: MouseEvent) => {\n this.lineClick.next({ target: edge, event: e });\n this.selectedEdge.set(edge);\n });\n line.addEventListener('dblclick', (e: MouseEvent) => {\n this.lineDbClick.next({ target: edge, event: e });\n });\n return line;\n }\n\n private finishConnection() {\n if (this.currentConnection?.source && this.currentConnection?.target) {\n this.pushAndCreateEdgeData(this.currentConnection.source, this.currentConnection.target);\n }\n this.currentConnection = null;\n }\n\n removeEdge(edge: AXFlowChartEdges) {\n this.initialFlowChartEdge.update((value) => value.filter((e) => e.id !== edge.id));\n\n // Remove selected class from connected anchors\n const sourceNode = this.nodesMap.get(edge.source.id);\n const targetNode = this.nodesMap.get(edge.target.id);\n\n if (sourceNode) {\n const sourceAnchor = sourceNode.querySelector(`[data-anchor=\"${edge.source.anchor}\"]`);\n if (sourceAnchor) sourceAnchor.classList.remove('selected');\n }\n\n if (targetNode) {\n const targetAnchor = targetNode.querySelector(`[data-anchor=\"${edge.target.anchor}\"]`);\n if (targetAnchor) targetAnchor.classList.remove('selected');\n }\n }\n\n createNode(nodes: { id: string; type: string; label: string; x: number; y: number }[]) {\n document.querySelectorAll('.ax-flow-chart-node')?.forEach((node) => node.remove());\n\n nodes.forEach((node) => {\n const el = document.createElement('div') as HTMLElementWithDataset;\n const p = document.createElement('p') as HTMLElementWithDataset;\n p.innerText = node.label;\n el.appendChild(p);\n el.className = 'ax-flow-chart-node';\n el.classList.add(`ax-${node.type}`);\n el.style.left = node.x + 'px';\n el.style.top = node.y + 'px';\n el.dataset['id'] = node.id;\n\n this.addAnchors(el, node.type);\n this.makeDraggable(el);\n this.setupNodeEventListeners(el, node);\n\n this.canvasService().nativeElement.appendChild(el);\n this.nodesMap.set(node.id, el);\n });\n }\n\n removeNode(nodeId: string) {\n this.initialFlowChartNode.update((value) => value.filter((e) => e.id !== nodeId));\n\n this.initialFlowChartEdge().forEach((edge) => {\n if (edge.source.id === nodeId || edge.target.id === nodeId) {\n this.removeEdge(edge);\n }\n });\n\n document.querySelector(`[data-id=\"${nodeId}\"]`)?.remove();\n this.anchorClickBuffer = null;\n }\n\n cleanup() {\n this.nodesMap.forEach((_, id) => this.removeEventListeners(id));\n this.nodesMap.clear();\n this.eventListeners.clear();\n }\n}\n","import { AXComponent, NXComponent } from '@acorex/cdk/common';\nimport { AXButtonModule } from '@acorex/components/button';\nimport { AXTextBoxModule } from '@acorex/components/text-box';\nimport { CommonModule } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, inject, signal, ViewEncapsulation } from '@angular/core';\nimport { FormsModule } from '@angular/forms';\nimport { AXFlowChartService } from '../flow-chart.service';\n\n@Component({\n selector: 'ax-flow-chart-creator',\n templateUrl: './flow-chart-creator.component.html',\n styleUrls: ['./flow-chart-creator.component.compiled.css'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n imports: [AXTextBoxModule, AXButtonModule, CommonModule, FormsModule],\n providers: [{ provide: AXComponent, useExisting: AXFlowChartCreatorComponent }],\n})\nexport class AXFlowChartCreatorComponent extends NXComponent {\n service = inject(AXFlowChartService);\n protected selectedShape = signal('rectangle');\n protected label = 'Label';\n\n protected selectShapeHandler(shape: 'rectangle' | 'circle' | 'diamond') {\n this.selectedShape.set(shape);\n }\n\n protected createShapeHandler() {\n const newNode = {\n id: Math.random().toString(),\n type: this.selectedShape(),\n label: this.label,\n x: 0,\n y: 0,\n };\n this.service.initialFlowChartNode.update((value) => [...value, newNode]);\n this.service.onNodeUpdate.next(newNode);\n }\n\n protected printChart(): void {\n const printWindow = window.open('', '_blank');\n if (!printWindow) return;\n\n const canvas = this.service.canvasService()?.nativeElement;\n if (!canvas) return;\n\n // Get all styles from the document and component\n const styles = Array.from(document.styleSheets)\n .map((sheet) => {\n try {\n return Array.from(sheet.cssRules)\n .map((rule) => rule.cssText)\n .join('\\n');\n } catch (e) {\n return '';\n }\n })\n .join('\\n');\n\n // Add print-specific styles for anchors\n const printStyles = `\n ${styles}\n .ax-flow-chart-anchor {\n opacity: 1 !important;\n }\n `;\n\n // Create the print content with proper styling\n const printContent = `\n <!DOCTYPE html>\n <html>\n <head>\n <title>Flow Chart Print</title>\n <style>\n ${printStyles}\n </style>\n </head>\n <body>\n <ax-flow-chart-renderer>\n ${canvas.outerHTML}\n </ax-flow-chart-renderer>\n </body>\n </html>\n `;\n\n printWindow.document.write(printContent);\n printWindow.document.close();\n }\n}\n","<div class=\"ax-shape-container\">\n <div\n [ngClass]=\"{ 'ax-shape-selected': selectedShape() === 'rectangle' }\"\n (click)=\"selectShapeHandler('rectangle')\"\n class=\"ax-rectangle\"\n ></div>\n <div\n [ngClass]=\"{ 'ax-shape-selected': selectedShape() === 'circle' }\"\n (click)=\"selectShapeHandler('circle')\"\n class=\"ax-circle\"\n ></div>\n <div\n [ngClass]=\"{ 'ax-shape-selected': selectedShape() === 'diamond' }\"\n (click)=\"selectShapeHandler('diamond')\"\n class=\"ax-diamond\"\n ></div>\n</div>\n<ax-text-box class=\"ax-sm\" [(ngModel)]=\"label\" placeholder=\"Label\"> </ax-text-box>\n\n<ax-button class=\"ax-sm\" (onClick)=\"createShapeHandler()\" color=\"primary\" text=\"Create\"></ax-button>\n<ax-button color=\"primary\" text=\"Print\" class=\"ax-sm\" (click)=\"printChart()\"></ax-button>\n","import { AXComponent, NXComponent } from '@acorex/cdk/common';\nimport {\n afterNextRender,\n ChangeDetectionStrategy,\n Component,\n effect,\n ElementRef,\n inject,\n OnDestroy,\n output,\n viewChild,\n ViewEncapsulation,\n} from '@angular/core';\nimport { AXFlowChartService } from '../flow-chart.service';\nimport { AXFlowChartEdges, AXFlowChartNodes, AXLineClickEvent, AXNodeClickEvent } from '../flow-chart.type';\n\n@Component({\n selector: 'ax-flow-chart-renderer',\n templateUrl: './flow-chart-renderer.component.html',\n styleUrls: ['./flow-chart-renderer.component.compiled.css'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n providers: [{ provide: AXComponent, useExisting: AXFlowChartRendererComponent }],\n})\nexport class AXFlowChartRendererComponent extends NXComponent implements OnDestroy {\n private canvas = viewChild<ElementRef>('canvas');\n private svg = viewChild<ElementRef>('connections');\n private service = inject(AXFlowChartService);\n\n readonly onLineClick = output<AXLineClickEvent>();\n readonly onLineDbClick = output<AXLineClickEvent>();\n readonly onNodeClick = output<AXNodeClickEvent>();\n readonly onNodeDbClick = output<AXNodeClickEvent>();\n readonly onEdgeUpdate = output<AXFlowChartEdges>();\n readonly onNodeUpdate = output<AXFlowChartNodes>();\n\n #init = afterNextRender(() => {\n this.setupEventListeners();\n });\n\n #eff = effect(() => {\n if (this.canvas() && this.svg()) {\n this.initializeServices();\n }\n });\n\n private setupEventListeners(): void {\n this.service.lineClick.subscribe((value) => {\n this.onLineClick.emit(value);\n });\n this.service.lineDbClick.subscribe((value) => {\n this.onLineDbClick.emit(value);\n });\n this.service.nodeClick.subscribe((value) => {\n this.onNodeClick.emit(value);\n });\n this.service.nodeDbClick.subscribe((value) => {\n this.onNodeDbClick.emit(value);\n });\n this.service.onEdgeUpdate.subscribe((newEdge) => {\n this.onEdgeUpdate.emit(newEdge);\n });\n this.service.onNodeUpdate.subscribe((newNode) => {\n this.onNodeUpdate.emit(newNode);\n });\n }\n\n private initializeServices(): void {\n this.service.canvasService.set(this.canvas());\n this.service.svgService.set(this.svg());\n\n // Add click handlers for parent elements\n const canvas = this.canvas()?.nativeElement;\n const svg = this.svg()?.nativeElement;\n\n if (canvas) {\n canvas.addEventListener('click', (e: Event) => {\n if (e.target === canvas) {\n this.service.selectedNode.set(null);\n this.service.selectedEdge.set(null);\n document.querySelectorAll('.ax-flow-chart-node').forEach((node) => node.classList.remove('selected'));\n document.querySelectorAll('.ax-flow-chart-line').forEach((line) => line.classList.remove('selected'));\n }\n });\n }\n\n if (svg) {\n svg.addEventListener('click', (e: Event) => {\n if (e.target === svg) {\n this.service.selectedNode.set(null);\n this.service.selectedEdge.set(null);\n document.querySelectorAll('.ax-flow-chart-node').forEach((node) => node.classList.remove('selected'));\n document.querySelectorAll('.ax-flow-chart-line').forEach((line) => line.classList.remove('selected'));\n }\n });\n }\n }\n\n ngOnDestroy(): void {\n this.cleanup();\n }\n\n private cleanup(): void {\n this.service.cleanup();\n this.service.lineClick.unsubscribe();\n this.service.lineDbClick.unsubscribe();\n this.service.nodeClick.unsubscribe();\n this.service.nodeDbClick.unsubscribe();\n this.service.onEdgeUpdate.unsubscribe();\n }\n}\n","<div id=\"ax-flow-chart-renderer-canvas\" #canvas>\n <svg class=\"ax-flow-chart-renderer-svg\" id=\"ax-flow-chart-renderer-connections\" #connections></svg>\n</div>\n","import { AXComponent, AXFocusableComponent, AXValuableComponent, NXComponent } from '@acorex/cdk/common';\nimport {\n afterNextRender,\n ChangeDetectionStrategy,\n Component,\n computed,\n HostListener,\n inject,\n input,\n ViewEncapsulation,\n} from '@angular/core';\nimport { AXFlowChartService } from './flow-chart.service';\nimport { AXFlowChartEdges, AXFlowChartNodes } from './flow-chart.type';\n\n@Component({\n selector: 'ax-flow-chart',\n templateUrl: './flow-chart.component.html',\n styleUrls: ['./flow-chart.component.compiled.css'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n providers: [\n AXFlowChartService,\n { provide: AXComponent, useExisting: AXFlowChartComponent },\n { provide: AXValuableComponent, useExisting: AXFlowChartComponent },\n { provide: AXFocusableComponent, useExisting: AXFlowChartComponent },\n ],\n})\nexport class AXFlowChartComponent extends NXComponent {\n private flowChartService = inject(AXFlowChartService);\n\n initialFlowChartNode = input.required<AXFlowChartNodes[]>();\n initialFlowChartEdge = input.required<AXFlowChartEdges[]>();\n selectedNode = computed(() => this.flowChartService.selectedNode());\n selectedEdge = computed(() => this.flowChartService.selectedEdge());\n\n #init = afterNextRender(() => {\n this.flowChartService.initialFlowChartNode.set(this.initialFlowChartNode());\n this.flowChartService.initialFlowChartEdge.set(this.initialFlowChartEdge());\n });\n\n @HostListener('document:keydown', ['$event'])\n handleKeyboardEvent(event: KeyboardEvent) {\n if (event.key === 'Delete') {\n const selectedNode = this.selectedNode();\n const selectedEdge = this.selectedEdge();\n\n if (selectedNode) {\n this.removeNode(selectedNode.id);\n } else if (selectedEdge) {\n this.removeEdge(selectedEdge);\n }\n }\n }\n\n /**\n * Draws edges on the flow chart.\n *\n * @param edges Array of edges to draw.\n * @returns void\n */\n drawEdges(edges: AXFlowChartEdges[]) {\n this.flowChartService.drawEdges(edges);\n }\n\n /**\n * Removes a specific edge from the flow chart.\n *\n * @param edge The edge object to remove.\n * @returns void\n */\n removeEdge(edge: AXFlowChartEdges) {\n this.flowChartService.removeEdge(edge);\n }\n\n /**\n * Creates one or more nodes on the flow chart.\n *\n * @param nodes Array of node definitions to create.\n * @returns void\n */\n createNode(nodes: { id: string; type: string; label: string; x: number; y: number }[]) {\n this.flowChartService.createNode(nodes);\n }\n\n /**\n * Removes a node by its identifier.\n *\n * @param nodeId The unique id of the node to remove.\n * @returns void\n */\n removeNode(nodeId: string) {\n this.flowChartService.removeNode(nodeId);\n }\n}\n","<ng-content select=\"ax-header\"></ng-content>\n<ng-content select=\"ax-flow-chart-renderer\"></ng-content>\n<ng-content select=\"ax-footer\"></ng-content>\n","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { AXFlowChartCreatorComponent } from './flow-chart-creator/flow-chart-creator.component';\nimport { AXFlowChartRendererComponent } from './flow-chart-renderer/flow-chart-renderer.component';\nimport { AXFlowChartComponent } from './flow-chart.component';\n\nconst COMPONENT = [AXFlowChartRendererComponent, AXFlowChartCreatorComponent, AXFlowChartComponent];\nconst MODULES = [CommonModule];\n\n@NgModule({\n imports: [...MODULES, ...COMPONENT],\n exports: [...COMPONENT],\n providers: [],\n})\nexport class AXFlowChartModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;MAWa,kBAAkB,CAAA;AAD/B,IAAA,WAAA,GAAA;AAEU,QAAA,IAAA,CAAA,IAAI,GAAG,MAAM,CAAC,MAAM,CAAC;AAE7B,QAAA,IAAA,CAAA,oBAAoB,GAAG,MAAM,CAAC,EAAE,gEAAC;AACjC,QAAA,IAAA,CAAA,oBAAoB,GAAG,MAAM,CAAC,EAAE,gEAAC;AACjC,QAAA,IAAA,CAAA,YAAY,GAAG,MAAM,CAA0B,IAAI,wDAAC;AACpD,QAAA,IAAA,CAAA,YAAY,GAAG,MAAM,CAA0B,IAAI,wDAAC;AAC3C,QAAA,IAAA,CAAA,UAAU,GAAG,MAAM,CAAC,IAAI,sDAAC;AACzB,QAAA,IAAA,CAAA,aAAa,GAAG,MAAM,CAAC,IAAI,yDAAC;AAE5B,Q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;uBAAC,kBAAkB,EAAE,CAAC,QAAQ,CAAC;;;AElC9C,MAAM,SAAS,GAAG,CAAC,4BAA4B,EAAE,2BAA2B,EAAE,oBAAoB,CAAC;AACnG,MAAM,OAAO,GAAG,CAAC,YAAY,CAAC;MAOjB,iBAAiB,CAAA;8GAAjB,iBAAiB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;AAAjB,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,iBAAiB,EAAA,OAAA,EAAA,CAPb,YAAY,EADV,4BAA4B,EAAE,2BAA2B,EAAE,oBAAoB,CAAA,EAAA,OAAA,EAAA,CAA/E,4BAA4B,EAAE,2BAA2B,EAAE,oBAAoB,CAAA,EAAA,CAAA,CAAA;+GAQrF,iBAAiB,EAAA,OAAA,EAAA,CAJf,OAAO,EAJ2B,2BAA2B,CAAA,EAAA,CAAA,CAAA;;2FAQ/D,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAL7B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,CAAC,GAAG,OAAO,EAAE,GAAG,SAAS,CAAC;AACnC,oBAAA,OAAO,EAAE,CAAC,GAAG,SAAS,CAAC;AACvB,oBAAA,SAAS,EAAE,EAAE;AACd,iBAAA;;;ACbD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"acorex-components-flow-chart.mjs","sources":["../../../../packages/components/flow-chart/src/lib/flow-chart.service.ts","../../../../packages/components/flow-chart/src/lib/flow-chart-creator/flow-chart-creator.component.ts","../../../../packages/components/flow-chart/src/lib/flow-chart-creator/flow-chart-creator.component.html","../../../../packages/components/flow-chart/src/lib/flow-chart-renderer/flow-chart-renderer.component.ts","../../../../packages/components/flow-chart/src/lib/flow-chart-renderer/flow-chart-renderer.component.html","../../../../packages/components/flow-chart/src/lib/flow-chart.component.ts","../../../../packages/components/flow-chart/src/lib/flow-chart.component.html","../../../../packages/components/flow-chart/src/lib/flow-chart.module.ts","../../../../packages/components/flow-chart/src/acorex-components-flow-chart.ts"],"sourcesContent":["import { DOCUMENT, isPlatformBrowser } from '@angular/common';\nimport { effect, inject, Injectable, NgZone, PLATFORM_ID, signal } from '@angular/core';\nimport { Subject } from 'rxjs';\nimport {\n AXFlowChartEdges,\n AXFlowChartNodes,\n AXLineClickEvent,\n AXNodeClickEvent,\n HTMLElementWithDataset,\n} from './flow-chart.type';\n\n@Injectable()\nexport class AXFlowChartService {\n private zone = inject(NgZone);\n private platformId = inject(PLATFORM_ID);\n private document = inject(DOCUMENT);\n\n initialFlowChartEdge = signal([]);\n initialFlowChartNode = signal([]);\n selectedNode = signal<AXFlowChartNodes | null>(null);\n selectedEdge = signal<AXFlowChartEdges | null>(null);\n readonly svgService = signal(null);\n readonly canvasService = signal(null);\n\n readonly lineClick = new Subject<AXLineClickEvent>();\n readonly lineDbClick = new Subject<AXLineClickEvent>();\n readonly nodeClick = new Subject<AXNodeClickEvent>();\n readonly nodeDbClick = new Subject<AXNodeClickEvent>();\n readonly onEdgeUpdate = new Subject<AXFlowChartEdges>();\n readonly onNodeUpdate = new Subject<AXFlowChartNodes>();\n\n private nodesMap = new Map<string, HTMLElementWithDataset>();\n private eventListeners = new Map<string, Map<string, EventListener>>();\n private anchorClickBuffer: { nodeId: string; anchor: string } | null = null;\n\n private currentConnection: {\n source?: { id: string; anchor: string };\n target?: { id: string; anchor: string };\n mouse?: { x: number; y: number };\n } | null = null;\n private draggingConnection = false;\n private tempLine: SVGLineElement | null = null;\n\n #eff2 = effect(() => {\n if (!isPlatformBrowser(this.platformId) || !this.initialFlowChartEdge()) {\n return;\n }\n\n setTimeout(() => {\n this.drawEdges(this.initialFlowChartEdge());\n });\n });\n\n #eff3 = effect(() => {\n if (!isPlatformBrowser(this.platformId) || !this.initialFlowChartNode()) {\n return;\n }\n\n this.createNode(this.initialFlowChartNode());\n });\n\n private addEventListener(element: HTMLElement, event: string, handler: EventListener) {\n const elementId = element.dataset['id'] || 'global';\n if (!this.eventListeners.has(elementId)) {\n this.eventListeners.set(elementId, new Map());\n }\n\n const elementListeners = this.eventListeners.get(elementId);\n if (elementListeners) {\n const boundHandler = handler.bind(this);\n elementListeners.set(event, boundHandler);\n element.addEventListener(event, boundHandler);\n }\n }\n\n private removeEventListeners(elementId: string) {\n const elementListeners = this.eventListeners.get(elementId);\n if (elementListeners) {\n elementListeners.forEach((handler, event) => {\n const element = this.nodesMap.get(elementId);\n if (element) {\n element.removeEventListener(event, handler);\n }\n });\n this.eventListeners.delete(elementId);\n }\n }\n\n private setupNodeEventListeners(\n el: HTMLElementWithDataset,\n node: { id: string; type: string; label: string; x: number; y: number },\n ) {\n this.addEventListener(el, 'click', (e: Event) => {\n this.nodeClick.next({ target: el, event: e as MouseEvent });\n this.selectedNode.set(node);\n el.classList.add('selected');\n this.nodesMap.forEach((existingNode) => {\n if (existingNode !== el) {\n existingNode.classList.remove('selected');\n }\n });\n });\n\n this.addEventListener(el, 'dblclick', (e: Event) => {\n this.nodeDbClick.next({ target: el, event: e as MouseEvent });\n });\n\n this.addEventListener(el, 'mouseenter', () => {\n el.classList.add('hover');\n });\n\n this.addEventListener(el, 'mouseleave', () => {\n el.classList.remove('hover');\n });\n }\n\n private setupAnchorEventListeners(dot: HTMLElementWithDataset, el: HTMLElementWithDataset) {\n // start drag to connect\n this.addEventListener(dot, 'mousedown', (e: Event) => {\n const mouseEvent = e as MouseEvent;\n mouseEvent.stopPropagation();\n mouseEvent.preventDefault();\n const pos = this.getAnchorPoint(el, dot.dataset['anchor']);\n\n this.currentConnection = {\n source: {\n id: dot.dataset['nodeId'],\n anchor: dot.dataset['anchor'],\n },\n mouse: { x: mouseEvent.clientX, y: mouseEvent.clientY },\n };\n\n this.startTempLine(pos.x, pos.y);\n this.draggingConnection = true;\n });\n\n this.addEventListener(dot, 'click', (e: Event) => {\n e.stopPropagation();\n\n if (dot.classList.contains('selected')) {\n dot.classList.remove('selected');\n } else {\n dot.classList.add('selected');\n }\n\n const clicked = {\n nodeId: dot.dataset['nodeId'],\n anchor: dot.dataset['anchor'],\n };\n\n console.log(clicked);\n\n if (!this.anchorClickBuffer) {\n this.anchorClickBuffer = clicked;\n } else {\n const source = this.anchorClickBuffer;\n const target = clicked;\n\n if (source.nodeId !== target.nodeId) {\n this.pushAndCreateEdgeData(\n { id: source.nodeId, anchor: source.anchor },\n { id: target.nodeId, anchor: target.anchor },\n );\n }\n\n this.anchorClickBuffer = null;\n }\n });\n\n this.addEventListener(dot, 'mouseenter', () => {\n dot.classList.add('hover');\n });\n\n this.addEventListener(dot, 'mouseleave', () => {\n dot.classList.remove('hover');\n });\n }\n\n private addAnchors(el: HTMLElementWithDataset, type: string) {\n ['top', 'bottom', 'left', 'right'].forEach((anchor) => {\n const dot = this.document.createElement('div') as HTMLElementWithDataset;\n dot.className = 'ax-flow-chart-anchor';\n dot.dataset['anchor'] = anchor;\n dot.dataset['nodeId'] = el.dataset['id'];\n\n this.positionAnchor(dot, anchor, type);\n el.appendChild(dot);\n\n this.setupAnchorEventListeners(dot, el);\n });\n }\n\n private makeDraggable(el: HTMLElement) {\n let offsetX = 0,\n offsetY = 0,\n isDragging = false;\n\n this.addEventListener(el, 'mousedown', (e: Event) => {\n const mouseEvent = e as MouseEvent;\n if ((mouseEvent.target as HTMLElement).classList.contains('ax-flow-chart-anchor')) return;\n isDragging = true;\n offsetX = mouseEvent.clientX - el.offsetLeft;\n offsetY = mouseEvent.clientY - el.offsetTop;\n mouseEvent.preventDefault();\n });\n\n const mousemoveHandler = (e: MouseEvent) => {\n if (isDragging) {\n el.style.left = e.clientX - offsetX + 'px';\n el.style.top = e.clientY - offsetY + 'px';\n this.drawEdges(this.initialFlowChartEdge());\n\n this.initialFlowChartNode.update((value) => {\n const node = value.find((node) => node.id === el.dataset['id']);\n if (node) {\n node.x = e.clientX - offsetX;\n node.y = e.clientY - offsetY;\n }\n return value;\n });\n }\n\n const elementId = (e.target as HTMLElement).id;\n if (elementId === 'ax-flow-chart-renderer-connections' || elementId === 'ax-flow-chart-renderer-canvas') {\n if (this.draggingConnection && this.tempLine) {\n this.tempLine.setAttribute('x2', e.offsetX.toString());\n this.tempLine.setAttribute('y2', e.offsetY.toString());\n }\n }\n };\n\n const mouseupHandler = (e: MouseEvent) => {\n isDragging = false;\n if (this.draggingConnection) {\n const target = (e.target as HTMLElement).closest('.ax-flow-chart-anchor') as HTMLElementWithDataset;\n if (target && target.dataset['nodeId'] !== this.currentConnection?.source?.id) {\n this.currentConnection = {\n ...this.currentConnection,\n target: {\n id: target.dataset['nodeId'],\n anchor: target.dataset['anchor'],\n },\n };\n this.finishConnection();\n }\n this.clearTempLine();\n this.draggingConnection = false;\n }\n };\n\n // Add global event listeners\n this.zone.runOutsideAngular(() => {\n this.document.addEventListener('mousemove', mousemoveHandler);\n this.document.addEventListener('mouseup', mouseupHandler);\n });\n\n // Store global listeners\n const globalListeners = this.eventListeners.get('global');\n if (globalListeners) {\n globalListeners.set('mousemove', mousemoveHandler as EventListener);\n globalListeners.set('mouseup', mouseupHandler as EventListener);\n }\n }\n\n private positionAnchor(dot: HTMLElement, anchor: string, type: string) {\n if (type !== 'diamond') {\n switch (anchor) {\n case 'top':\n dot.style.top = '0%';\n dot.style.left = '50%';\n break;\n case 'bottom':\n dot.style.top = '100%';\n dot.style.left = '50%';\n break;\n case 'left':\n dot.style.top = '50%';\n dot.style.left = '0%';\n break;\n case 'right':\n dot.style.top = '50%';\n dot.style.left = '100%';\n break;\n }\n } else {\n switch (anchor) {\n case 'top':\n dot.style.top = '0%';\n dot.style.left = '0%';\n break;\n case 'bottom':\n dot.style.top = '100%';\n dot.style.left = '100%';\n break;\n case 'left':\n dot.style.top = '100%';\n dot.style.left = '0%';\n break;\n case 'right':\n dot.style.top = '0%';\n dot.style.left = '100%';\n break;\n }\n }\n }\n\n private getAnchorPoint(el: HTMLElement, anchor: string): { x: number; y: number } {\n const rect = el.getBoundingClientRect();\n const centerX = el.offsetLeft + rect.width / 2;\n const centerY = el.offsetTop + rect.height / 2;\n\n switch (anchor) {\n case 'top':\n return { x: centerX, y: el.offsetTop };\n case 'bottom':\n return { x: centerX, y: el.offsetTop + rect.height };\n case 'left':\n return { x: el.offsetLeft, y: centerY };\n case 'right':\n return { x: el.offsetLeft + rect.width, y: centerY };\n default:\n return { x: centerX, y: centerY };\n }\n }\n\n private startTempLine(x: number, y: number) {\n const svgElement = this.svgService()?.nativeElement;\n\n if (!svgElement) return;\n\n this.tempLine = this.document.createElementNS('http://www.w3.org/2000/svg', 'line');\n this.tempLine.setAttribute('x1', x.toString());\n this.tempLine.setAttribute('y1', y.toString());\n this.tempLine.setAttribute('x2', x.toString());\n this.tempLine.setAttribute('y2', y.toString());\n this.tempLine.setAttribute('stroke', 'rgba(var(--ax-sys-color-on-lightest-surface),0.5)');\n this.tempLine.setAttribute('stroke-width', '2');\n this.tempLine.setAttribute('stroke-dasharray', '4');\n svgElement.appendChild(this.tempLine);\n }\n\n private clearTempLine() {\n if (this.tempLine && this.tempLine.parentElement) {\n this.svgService()?.nativeElement.removeChild(this.tempLine);\n this.tempLine = null;\n }\n }\n\n private pushAndCreateEdgeData(source: { id: string; anchor: string }, target: { id: string; anchor: string }) {\n const newEdge = {\n id: `edge-${Math.random().toString()}`,\n source,\n target,\n };\n\n this.onEdgeUpdate.next(newEdge);\n this.initialFlowChartEdge.update((value) => [...value, newEdge]);\n this.drawEdges();\n }\n\n drawEdges(edges?: AXFlowChartEdges[]) {\n if (!isPlatformBrowser(this.platformId)) {\n return;\n }\n\n const svg = this.svgService()?.nativeElement;\n if (!svg) return;\n\n // Clear existing edges\n svg.innerHTML = '';\n\n // Use provided edges or get from signal\n const edgesToDraw = edges || this.initialFlowChartEdge();\n\n edgesToDraw.forEach((edge) => {\n const sourceNode = this.nodesMap.get(edge.source.id);\n const targetNode = this.nodesMap.get(edge.target.id);\n\n if (sourceNode) {\n const sourceAnchor = sourceNode.querySelector(`[data-anchor=\"${edge.source.anchor}\"]`);\n if (sourceAnchor) sourceAnchor.classList.add('selected');\n }\n if (targetNode) {\n const targetAnchor = targetNode.querySelector(`[data-anchor=\"${edge.target.anchor}\"]`);\n if (targetAnchor) targetAnchor.classList.add('selected');\n }\n\n if (sourceNode && targetNode) {\n const sourcePoint = this.getAnchorPoint(sourceNode, edge.source.anchor);\n const targetPoint = this.getAnchorPoint(targetNode, edge.target.anchor);\n\n const line = this.createLine(sourcePoint, targetPoint, edge);\n line.classList.add('ax-flow-chart-line');\n\n // Add click event listener for line selection\n this.addEventListener(line as unknown as HTMLElement, 'click', (e: Event) => {\n e.stopPropagation();\n this.lineClick.next({ target: edge, event: e as MouseEvent });\n this.selectedEdge.set(edge);\n this.selectedNode.set(null);\n // Remove selection from all other lines\n this.document.querySelectorAll('.ax-flow-chart-line').forEach((l) => {\n if (l !== line) l.classList.remove('selected');\n });\n // Add selection to clicked line\n line.classList.add('selected');\n // Remove selection from all nodes\n this.nodesMap.forEach((node) => node.classList.remove('selected'));\n });\n\n svg.appendChild(line);\n }\n });\n }\n\n createLine(from: { x: number; y: number }, to: { x: number; y: number }, edge: AXFlowChartEdges) {\n const line = this.document.createElementNS('http://www.w3.org/2000/svg', 'line');\n line.setAttribute('x1', from.x.toString());\n line.setAttribute('y1', from.y.toString());\n line.setAttribute('x2', to.x.toString());\n line.setAttribute('y2', to.y.toString());\n line.setAttribute('stroke', 'rgba(var(--ax-sys-color-on-surface))');\n line.setAttribute('stroke-width', '3');\n line.classList.add('ax-flow-chart-line');\n line.addEventListener('click', (e: MouseEvent) => {\n this.lineClick.next({ target: edge, event: e });\n this.selectedEdge.set(edge);\n });\n line.addEventListener('dblclick', (e: MouseEvent) => {\n this.lineDbClick.next({ target: edge, event: e });\n });\n return line;\n }\n\n private finishConnection() {\n if (this.currentConnection?.source && this.currentConnection?.target) {\n this.pushAndCreateEdgeData(this.currentConnection.source, this.currentConnection.target);\n }\n this.currentConnection = null;\n }\n\n removeEdge(edge: AXFlowChartEdges) {\n this.initialFlowChartEdge.update((value) => value.filter((e) => e.id !== edge.id));\n\n // Remove selected class from connected anchors\n const sourceNode = this.nodesMap.get(edge.source.id);\n const targetNode = this.nodesMap.get(edge.target.id);\n\n if (sourceNode) {\n const sourceAnchor = sourceNode.querySelector(`[data-anchor=\"${edge.source.anchor}\"]`);\n if (sourceAnchor) sourceAnchor.classList.remove('selected');\n }\n\n if (targetNode) {\n const targetAnchor = targetNode.querySelector(`[data-anchor=\"${edge.target.anchor}\"]`);\n if (targetAnchor) targetAnchor.classList.remove('selected');\n }\n }\n\n createNode(nodes: { id: string; type: string; label: string; x: number; y: number }[]) {\n if (!isPlatformBrowser(this.platformId)) {\n return;\n }\n\n const canvas = this.canvasService()?.nativeElement;\n if (!canvas) {\n return;\n }\n\n this.document.querySelectorAll('.ax-flow-chart-node')?.forEach((node) => node.remove());\n\n nodes.forEach((node) => {\n const el = this.document.createElement('div') as HTMLElementWithDataset;\n const p = this.document.createElement('p') as HTMLElementWithDataset;\n p.innerText = node.label;\n el.appendChild(p);\n el.className = 'ax-flow-chart-node';\n el.classList.add(`ax-${node.type}`);\n el.style.left = node.x + 'px';\n el.style.top = node.y + 'px';\n el.dataset['id'] = node.id;\n\n this.addAnchors(el, node.type);\n this.makeDraggable(el);\n this.setupNodeEventListeners(el, node);\n\n canvas.appendChild(el);\n this.nodesMap.set(node.id, el);\n });\n }\n\n removeNode(nodeId: string) {\n this.initialFlowChartNode.update((value) => value.filter((e) => e.id !== nodeId));\n\n this.initialFlowChartEdge().forEach((edge) => {\n if (edge.source.id === nodeId || edge.target.id === nodeId) {\n this.removeEdge(edge);\n }\n });\n\n this.document.querySelector(`[data-id=\"${nodeId}\"]`)?.remove();\n this.anchorClickBuffer = null;\n }\n\n cleanup() {\n this.nodesMap.forEach((_, id) => this.removeEventListeners(id));\n this.nodesMap.clear();\n this.eventListeners.clear();\n }\n}\n","import { AXComponent, NXComponent } from '@acorex/cdk/common';\nimport { AXButtonModule } from '@acorex/components/button';\nimport { AXTextBoxModule } from '@acorex/components/text-box';\nimport { CommonModule } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, inject, signal, ViewEncapsulation } from '@angular/core';\nimport { FormsModule } from '@angular/forms';\nimport { AXFlowChartService } from '../flow-chart.service';\n\n@Component({\n selector: 'ax-flow-chart-creator',\n templateUrl: './flow-chart-creator.component.html',\n styleUrls: ['./flow-chart-creator.component.compiled.css'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n imports: [AXTextBoxModule, AXButtonModule, CommonModule, FormsModule],\n providers: [{ provide: AXComponent, useExisting: AXFlowChartCreatorComponent }],\n})\nexport class AXFlowChartCreatorComponent extends NXComponent {\n service = inject(AXFlowChartService);\n protected selectedShape = signal('rectangle');\n protected label = 'Label';\n\n protected selectShapeHandler(shape: 'rectangle' | 'circle' | 'diamond') {\n this.selectedShape.set(shape);\n }\n\n protected createShapeHandler() {\n const newNode = {\n id: Math.random().toString(),\n type: this.selectedShape(),\n label: this.label,\n x: 0,\n y: 0,\n };\n this.service.initialFlowChartNode.update((value) => [...value, newNode]);\n this.service.onNodeUpdate.next(newNode);\n }\n\n protected printChart(): void {\n const printWindow = window.open('', '_blank');\n if (!printWindow) return;\n\n const canvas = this.service.canvasService()?.nativeElement;\n if (!canvas) return;\n\n // Get all styles from the document and component\n const styles = Array.from(document.styleSheets)\n .map((sheet) => {\n try {\n return Array.from(sheet.cssRules)\n .map((rule) => rule.cssText)\n .join('\\n');\n } catch (e) {\n return '';\n }\n })\n .join('\\n');\n\n // Add print-specific styles for anchors\n const printStyles = `\n ${styles}\n .ax-flow-chart-anchor {\n opacity: 1 !important;\n }\n `;\n\n // Create the print content with proper styling\n const printContent = `\n <!DOCTYPE html>\n <html>\n <head>\n <title>Flow Chart Print</title>\n <style>\n ${printStyles}\n </style>\n </head>\n <body>\n <ax-flow-chart-renderer>\n ${canvas.outerHTML}\n </ax-flow-chart-renderer>\n </body>\n </html>\n `;\n\n printWindow.document.write(printContent);\n printWindow.document.close();\n }\n}\n","<div class=\"ax-shape-container\">\n <div\n [ngClass]=\"{ 'ax-shape-selected': selectedShape() === 'rectangle' }\"\n (click)=\"selectShapeHandler('rectangle')\"\n class=\"ax-rectangle\"\n ></div>\n <div\n [ngClass]=\"{ 'ax-shape-selected': selectedShape() === 'circle' }\"\n (click)=\"selectShapeHandler('circle')\"\n class=\"ax-circle\"\n ></div>\n <div\n [ngClass]=\"{ 'ax-shape-selected': selectedShape() === 'diamond' }\"\n (click)=\"selectShapeHandler('diamond')\"\n class=\"ax-diamond\"\n ></div>\n</div>\n<ax-text-box class=\"ax-sm\" [(ngModel)]=\"label\" placeholder=\"Label\"> </ax-text-box>\n\n<ax-button class=\"ax-sm\" (onClick)=\"createShapeHandler()\" color=\"primary\" text=\"Create\"></ax-button>\n<ax-button color=\"primary\" text=\"Print\" class=\"ax-sm\" (click)=\"printChart()\"></ax-button>\n","import { AXComponent, NXComponent } from '@acorex/cdk/common';\nimport { DOCUMENT, isPlatformBrowser } from '@angular/common';\nimport {\n afterNextRender,\n ChangeDetectionStrategy,\n Component,\n effect,\n ElementRef,\n inject,\n OnDestroy,\n output,\n PLATFORM_ID,\n viewChild,\n ViewEncapsulation,\n} from '@angular/core';\nimport { AXFlowChartService } from '../flow-chart.service';\nimport { AXFlowChartEdges, AXFlowChartNodes, AXLineClickEvent, AXNodeClickEvent } from '../flow-chart.type';\n\n@Component({\n selector: 'ax-flow-chart-renderer',\n templateUrl: './flow-chart-renderer.component.html',\n styleUrls: ['./flow-chart-renderer.component.compiled.css'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n providers: [{ provide: AXComponent, useExisting: AXFlowChartRendererComponent }],\n})\nexport class AXFlowChartRendererComponent extends NXComponent implements OnDestroy {\n private canvas = viewChild<ElementRef>('canvas');\n private svg = viewChild<ElementRef>('connections');\n private service = inject(AXFlowChartService);\n private document = inject(DOCUMENT);\n private platformId = inject(PLATFORM_ID);\n\n readonly onLineClick = output<AXLineClickEvent>();\n readonly onLineDbClick = output<AXLineClickEvent>();\n readonly onNodeClick = output<AXNodeClickEvent>();\n readonly onNodeDbClick = output<AXNodeClickEvent>();\n readonly onEdgeUpdate = output<AXFlowChartEdges>();\n readonly onNodeUpdate = output<AXFlowChartNodes>();\n\n #init = afterNextRender(() => {\n this.setupEventListeners();\n });\n\n #eff = effect(() => {\n if (!isPlatformBrowser(this.platformId) || !this.canvas() || !this.svg()) {\n return;\n }\n\n this.initializeServices();\n });\n\n private setupEventListeners(): void {\n this.service.lineClick.subscribe((value) => {\n this.onLineClick.emit(value);\n });\n this.service.lineDbClick.subscribe((value) => {\n this.onLineDbClick.emit(value);\n });\n this.service.nodeClick.subscribe((value) => {\n this.onNodeClick.emit(value);\n });\n this.service.nodeDbClick.subscribe((value) => {\n this.onNodeDbClick.emit(value);\n });\n this.service.onEdgeUpdate.subscribe((newEdge) => {\n this.onEdgeUpdate.emit(newEdge);\n });\n this.service.onNodeUpdate.subscribe((newNode) => {\n this.onNodeUpdate.emit(newNode);\n });\n }\n\n private initializeServices(): void {\n this.service.canvasService.set(this.canvas());\n this.service.svgService.set(this.svg());\n\n // Add click handlers for parent elements\n const canvas = this.canvas()?.nativeElement;\n const svg = this.svg()?.nativeElement;\n\n if (canvas) {\n canvas.addEventListener('click', (e: Event) => {\n if (e.target === canvas) {\n this.service.selectedNode.set(null);\n this.service.selectedEdge.set(null);\n this.document.querySelectorAll('.ax-flow-chart-node').forEach((node) => node.classList.remove('selected'));\n this.document.querySelectorAll('.ax-flow-chart-line').forEach((line) => line.classList.remove('selected'));\n }\n });\n }\n\n if (svg) {\n svg.addEventListener('click', (e: Event) => {\n if (e.target === svg) {\n this.service.selectedNode.set(null);\n this.service.selectedEdge.set(null);\n this.document.querySelectorAll('.ax-flow-chart-node').forEach((node) => node.classList.remove('selected'));\n this.document.querySelectorAll('.ax-flow-chart-line').forEach((line) => line.classList.remove('selected'));\n }\n });\n }\n }\n\n ngOnDestroy(): void {\n this.cleanup();\n }\n\n private cleanup(): void {\n this.service.cleanup();\n this.service.lineClick.unsubscribe();\n this.service.lineDbClick.unsubscribe();\n this.service.nodeClick.unsubscribe();\n this.service.nodeDbClick.unsubscribe();\n this.service.onEdgeUpdate.unsubscribe();\n }\n}\n","<div id=\"ax-flow-chart-renderer-canvas\" #canvas>\n <svg class=\"ax-flow-chart-renderer-svg\" id=\"ax-flow-chart-renderer-connections\" #connections></svg>\n</div>\n","import { AXComponent, AXFocusableComponent, AXValuableComponent, NXComponent } from '@acorex/cdk/common';\nimport {\n afterNextRender,\n ChangeDetectionStrategy,\n Component,\n computed,\n HostListener,\n inject,\n input,\n ViewEncapsulation,\n} from '@angular/core';\nimport { AXFlowChartService } from './flow-chart.service';\nimport { AXFlowChartEdges, AXFlowChartNodes } from './flow-chart.type';\n\n@Component({\n selector: 'ax-flow-chart',\n templateUrl: './flow-chart.component.html',\n styleUrls: ['./flow-chart.component.compiled.css'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n providers: [\n AXFlowChartService,\n { provide: AXComponent, useExisting: AXFlowChartComponent },\n { provide: AXValuableComponent, useExisting: AXFlowChartComponent },\n { provide: AXFocusableComponent, useExisting: AXFlowChartComponent },\n ],\n})\nexport class AXFlowChartComponent extends NXComponent {\n private flowChartService = inject(AXFlowChartService);\n\n initialFlowChartNode = input.required<AXFlowChartNodes[]>();\n initialFlowChartEdge = input.required<AXFlowChartEdges[]>();\n selectedNode = computed(() => this.flowChartService.selectedNode());\n selectedEdge = computed(() => this.flowChartService.selectedEdge());\n\n #init = afterNextRender(() => {\n this.flowChartService.initialFlowChartNode.set(this.initialFlowChartNode());\n this.flowChartService.initialFlowChartEdge.set(this.initialFlowChartEdge());\n });\n\n @HostListener('document:keydown', ['$event'])\n handleKeyboardEvent(event: KeyboardEvent) {\n if (event.key === 'Delete') {\n const selectedNode = this.selectedNode();\n const selectedEdge = this.selectedEdge();\n\n if (selectedNode) {\n this.removeNode(selectedNode.id);\n } else if (selectedEdge) {\n this.removeEdge(selectedEdge);\n }\n }\n }\n\n /**\n * Draws edges on the flow chart.\n *\n * @param edges Array of edges to draw.\n * @returns void\n */\n drawEdges(edges: AXFlowChartEdges[]) {\n this.flowChartService.drawEdges(edges);\n }\n\n /**\n * Removes a specific edge from the flow chart.\n *\n * @param edge The edge object to remove.\n * @returns void\n */\n removeEdge(edge: AXFlowChartEdges) {\n this.flowChartService.removeEdge(edge);\n }\n\n /**\n * Creates one or more nodes on the flow chart.\n *\n * @param nodes Array of node definitions to create.\n * @returns void\n */\n createNode(nodes: { id: string; type: string; label: string; x: number; y: number }[]) {\n this.flowChartService.createNode(nodes);\n }\n\n /**\n * Removes a node by its identifier.\n *\n * @param nodeId The unique id of the node to remove.\n * @returns void\n */\n removeNode(nodeId: string) {\n this.flowChartService.removeNode(nodeId);\n }\n}\n","<ng-content select=\"ax-header\"></ng-content>\n<ng-content select=\"ax-flow-chart-renderer\"></ng-content>\n<ng-content select=\"ax-footer\"></ng-content>\n","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { AXFlowChartCreatorComponent } from './flow-chart-creator/flow-chart-creator.component';\nimport { AXFlowChartRendererComponent } from './flow-chart-renderer/flow-chart-renderer.component';\nimport { AXFlowChartComponent } from './flow-chart.component';\n\nconst COMPONENT = [AXFlowChartRendererComponent, AXFlowChartCreatorComponent, AXFlowChartComponent];\nconst MODULES = [CommonModule];\n\n@NgModule({\n imports: [...MODULES, ...COMPONENT],\n exports: [...COMPONENT],\n providers: [],\n})\nexport class AXFlowChartModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;MAYa,kBAAkB,CAAA;AAD/B,IAAA,WAAA,GAAA;AAEU,QAAA,IAAA,C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EAAA,CAAA,0XAAA,CAAA,EAAA;;sBAeA,YAAY;uBAAC,kBAAkB,EAAE,CAAC,QAAQ,CAAC;;;AElC9C,MAAM,SAAS,GAAG,CAAC,4BAA4B,EAAE,2BAA2B,EAAE,oBAAoB,CAAC;AACnG,MAAM,OAAO,GAAG,CAAC,YAAY,CAAC;MAOjB,iBAAiB,CAAA;8GAAjB,iBAAiB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;AAAjB,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,iBAAiB,EAAA,OAAA,EAAA,CAPb,YAAY,EADV,4BAA4B,EAAE,2BAA2B,EAAE,oBAAoB,CAAA,EAAA,OAAA,EAAA,CAA/E,4BAA4B,EAAE,2BAA2B,EAAE,oBAAoB,CAAA,EAAA,CAAA,CAAA;+GAQrF,iBAAiB,EAAA,OAAA,EAAA,CAJf,OAAO,EAJ2B,2BAA2B,CAAA,EAAA,CAAA,CAAA;;2FAQ/D,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAL7B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,CAAC,GAAG,OAAO,EAAE,GAAG,SAAS,CAAC;AACnC,oBAAA,OAAO,EAAE,CAAC,GAAG,SAAS,CAAC;AACvB,oBAAA,SAAS,EAAE,EAAE;AACd,iBAAA;;;ACbD;;AAEG;;;;"}
|
|
@@ -1,9 +1,12 @@
|
|
|
1
1
|
import { AXInputMaskDirective } from '@acorex/cdk/input-mask';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
|
-
import { input, model, signal, viewChild, afterNextRender, effect, forwardRef, HostBinding, ViewEncapsulation, ChangeDetectionStrategy, Component, NgModule } from '@angular/core';
|
|
3
|
+
import { input, model, signal, viewChild, inject, afterNextRender, effect, forwardRef, HostBinding, ViewEncapsulation, ChangeDetectionStrategy, Component, NgModule } from '@angular/core';
|
|
4
4
|
import { MXInputBaseValueComponent, MXLookComponent, AXComponent, AXFocusableComponent, AXClearableComponent, AXValuableComponent } from '@acorex/cdk/common';
|
|
5
5
|
import { AXButtonModule } from '@acorex/components/button';
|
|
6
6
|
import { AXDecoratorModule } from '@acorex/components/decorators';
|
|
7
|
+
import * as i2 from '@acorex/components/form';
|
|
8
|
+
import { AXFormModule } from '@acorex/components/form';
|
|
9
|
+
import { AXTranslationService } from '@acorex/core/translation';
|
|
7
10
|
import * as i1 from '@angular/forms';
|
|
8
11
|
import { FormsModule, NG_VALUE_ACCESSOR } from '@angular/forms';
|
|
9
12
|
import { classes } from 'polytype';
|
|
@@ -26,6 +29,30 @@ class AXNumberBoxComponent extends classes((MXInputBaseValueComponent), MXLookCo
|
|
|
26
29
|
this.mode = signal('digits', ...(ngDevMode ? [{ debugName: "mode" }] : []));
|
|
27
30
|
this.input = viewChild('input', ...(ngDevMode ? [{ debugName: "input" }] : []));
|
|
28
31
|
this.stringValue = signal('', ...(ngDevMode ? [{ debugName: "stringValue" }] : []));
|
|
32
|
+
this.translationService = inject(AXTranslationService);
|
|
33
|
+
this.validateFn = async (val) => {
|
|
34
|
+
const min = this.minValue();
|
|
35
|
+
if (min != null && val != null && val < min) {
|
|
36
|
+
const message = await this.translationService.translateAsync('@acorex:validation.messages.min', {
|
|
37
|
+
params: { value: min },
|
|
38
|
+
});
|
|
39
|
+
return {
|
|
40
|
+
result: false,
|
|
41
|
+
message,
|
|
42
|
+
};
|
|
43
|
+
}
|
|
44
|
+
const max = this.maxValue();
|
|
45
|
+
if (max != null && val != null && val > max) {
|
|
46
|
+
const message = await this.translationService.translateAsync('@acorex:validation.messages.max', {
|
|
47
|
+
params: { value: max },
|
|
48
|
+
});
|
|
49
|
+
return {
|
|
50
|
+
result: false,
|
|
51
|
+
message,
|
|
52
|
+
};
|
|
53
|
+
}
|
|
54
|
+
return { result: true };
|
|
55
|
+
};
|
|
29
56
|
this.#init = afterNextRender(() => {
|
|
30
57
|
this.onFocus.subscribe(() => {
|
|
31
58
|
this.input().nativeElement.select();
|
|
@@ -66,7 +93,7 @@ class AXNumberBoxComponent extends classes((MXInputBaseValueComponent), MXLookCo
|
|
|
66
93
|
return;
|
|
67
94
|
}
|
|
68
95
|
const currentValue = this.getNumericValue();
|
|
69
|
-
const nextValue = this.getSteppedValue(currentValue, 1);
|
|
96
|
+
const nextValue = this.clampToRange(this.getSteppedValue(currentValue, 1));
|
|
70
97
|
this.commitValue(nextValue, true);
|
|
71
98
|
if (this.mode() === 'thousandsSeparator') {
|
|
72
99
|
const addSeparator = nextValue.toLocaleString();
|
|
@@ -81,7 +108,7 @@ class AXNumberBoxComponent extends classes((MXInputBaseValueComponent), MXLookCo
|
|
|
81
108
|
return;
|
|
82
109
|
}
|
|
83
110
|
const currentValue = this.getNumericValue();
|
|
84
|
-
const nextValue = this.getSteppedValue(currentValue, -1);
|
|
111
|
+
const nextValue = this.clampToRange(this.getSteppedValue(currentValue, -1));
|
|
85
112
|
this.commitValue(nextValue, true);
|
|
86
113
|
if (this.mode() === 'thousandsSeparator') {
|
|
87
114
|
const addSeparator = nextValue.toLocaleString();
|
|
@@ -105,6 +132,17 @@ class AXNumberBoxComponent extends classes((MXInputBaseValueComponent), MXLookCo
|
|
|
105
132
|
const stepUnits = Math.round(step * scale) * direction;
|
|
106
133
|
return (currentUnits + stepUnits) / scale;
|
|
107
134
|
}
|
|
135
|
+
clampToRange(value) {
|
|
136
|
+
const min = this.minValue();
|
|
137
|
+
const max = this.maxValue();
|
|
138
|
+
if (min != null && value < min) {
|
|
139
|
+
return min;
|
|
140
|
+
}
|
|
141
|
+
if (max != null && value > max) {
|
|
142
|
+
return max;
|
|
143
|
+
}
|
|
144
|
+
return value;
|
|
145
|
+
}
|
|
108
146
|
getFractionDigits(value) {
|
|
109
147
|
if (!Number.isFinite(value)) {
|
|
110
148
|
return 0;
|
|
@@ -175,7 +213,7 @@ class AXNumberBoxComponent extends classes((MXInputBaseValueComponent), MXLookCo
|
|
|
175
213
|
useExisting: forwardRef(() => AXNumberBoxComponent),
|
|
176
214
|
multi: true,
|
|
177
215
|
},
|
|
178
|
-
], viewQueries: [{ propertyName: "input", first: true, predicate: ["input"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<div\n class=\"ax-editor-container ax-default ax-default {{ look }}\"\n [class.ax-state-disabled]=\"disabled\"\n [class.ax-state-readonly]=\"readonly\"\n>\n <ng-content select=\"ax-prefix\"> </ng-content>\n <input\n #input\n [name]=\"name\"\n axInputMask\n (onMaskChanged)=\"handleOnMaskChanged($event)\"\n [maskMode]=\"mode()\"\n inputmode=\"numeric\"\n class=\"ax-input\"\n [
|
|
216
|
+
], viewQueries: [{ propertyName: "input", first: true, predicate: ["input"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<div\n class=\"ax-editor-container ax-default ax-default {{ look }}\"\n [class.ax-state-disabled]=\"disabled\"\n [class.ax-state-readonly]=\"readonly\"\n>\n <ng-content select=\"ax-prefix\"> </ng-content>\n <input\n #input\n [name]=\"name\"\n axInputMask\n (onMaskChanged)=\"handleOnMaskChanged($event)\"\n [maskMode]=\"mode()\"\n inputmode=\"numeric\"\n class=\"ax-input\"\n [separator]=\"thousandsSeparator()\"\n [decimal]=\"decimals()\"\n [id]=\"id\"\n [attr.placeholder]=\"placeholder\"\n [attr.autocomplete]=\"'off'\"\n [class.ax-state-disabled]=\"disabled\"\n [class.ax-state-readonly]=\"readonly\"\n [disabled]=\"disabled\"\n [readonly]=\"readonly\"\n [tabindex]=\"tabIndex\"\n [(ngModel)]=\"stringValue\"\n (keydown)=\"handleOnKeydownEvent($event)\"\n (keyup)=\"emitOnKeyupEvent($event)\"\n (keypress)=\"emitOnKeypressEvent($event)\"\n (focus)=\"emitOnFocusEvent($event)\"\n (blur)=\"emitOnBlurEvent($event)\"\n (wheel)=\"onWheel($event)\"\n />\n @if (input.value && !disabled && !readonly) {\n <ng-content select=\"ax-clear-button\"></ng-content>\n }\n @if (showSpinButtons()) {\n <div class=\"ax-general-button-control\">\n <button\n type=\"button\"\n class=\"ax-general-button-icon\"\n [class.ax-state-disabled]=\"disabled\"\n (click)=\"handleUpClick()\"\n tabindex=\"-1\"\n [disabled]=\"disabled\"\n >\n <span class=\"ax-icon ax-icon-chevron-up ax-arrow-button\"></span>\n </button>\n <button\n type=\"button\"\n class=\"ax-general-button-icon\"\n [class.ax-state-disabled]=\"disabled\"\n (click)=\"handleDownClick()\"\n tabindex=\"-1\"\n [disabled]=\"disabled\"\n >\n <span class=\"ax-icon ax-icon-chevron-down ax-arrow-button\"></span>\n </button>\n </div>\n }\n\n <ng-content select=\"ax-suffix\"> </ng-content>\n</div>\n<ng-content select=\"ax-validation-rule\"> </ng-content>\n@if (minValue() != null || maxValue() != null) {\n <ax-validation-rule rule=\"callback\" [options]=\"{ validate: validateFn }\"></ax-validation-rule>\n}\n<div class=\"ax-error-container\"></div>\n", styles: ["@layer components{ax-number-box input::-webkit-outer-spin-button{-webkit-appearance:none;margin:calc(var(--spacing,.25rem) * 0)}ax-number-box input::-webkit-inner-spin-button{-webkit-appearance:none;margin:calc(var(--spacing,.25rem) * 0)}ax-number-box input[type=number]{-moz-appearance:textfield}ax-number-box .ax-general-button-control{flex-direction:column;width:fit-content;display:flex}ax-number-box .ax-general-button-control .ax-general-button-icon{height:calc(var(--spacing,.25rem) * 1)!important;padding:calc(var(--spacing,.25rem) * 1.5)!important;font-size:var(--text-xs,.75rem)!important;line-height:var(--tw-leading,var(--text-xs--line-height,calc(1 / .75)))!important}}\n/*! tailwindcss v4.3.0 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { 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"] }, { kind: "directive", type: AXInputMaskDirective, selector: "[axInputMask]", inputs: ["maskMode", "separator", "eager", "minValue", "maxValue", "decimal", "maskPattern", "customTokens"], outputs: ["onMaskChanged"], exportAs: ["axInputMask"] }, { kind: "ngmodule", type: AXButtonModule }, { kind: "ngmodule", type: AXDecoratorModule }, { kind: "ngmodule", type: AXFormModule }, { kind: "directive", type: i2.AXValidationRuleDirective, selector: "ax-validation-rule", inputs: ["rule", "options", "message", "disabled"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
179
217
|
}
|
|
180
218
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.3", ngImport: i0, type: AXNumberBoxComponent, decorators: [{
|
|
181
219
|
type: Component,
|
|
@@ -200,7 +238,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.1.3", ngImpor
|
|
|
200
238
|
useExisting: forwardRef(() => AXNumberBoxComponent),
|
|
201
239
|
multi: true,
|
|
202
240
|
},
|
|
203
|
-
], imports: [FormsModule, AXInputMaskDirective, AXButtonModule, AXDecoratorModule], template: "<div\n class=\"ax-editor-container ax-default ax-default {{ look }}\"\n [class.ax-state-disabled]=\"disabled\"\n [class.ax-state-readonly]=\"readonly\"\n>\n <ng-content select=\"ax-prefix\"> </ng-content>\n <input\n #input\n [name]=\"name\"\n axInputMask\n (onMaskChanged)=\"handleOnMaskChanged($event)\"\n [maskMode]=\"mode()\"\n inputmode=\"numeric\"\n class=\"ax-input\"\n [
|
|
241
|
+
], imports: [FormsModule, AXInputMaskDirective, AXButtonModule, AXDecoratorModule, AXFormModule], template: "<div\n class=\"ax-editor-container ax-default ax-default {{ look }}\"\n [class.ax-state-disabled]=\"disabled\"\n [class.ax-state-readonly]=\"readonly\"\n>\n <ng-content select=\"ax-prefix\"> </ng-content>\n <input\n #input\n [name]=\"name\"\n axInputMask\n (onMaskChanged)=\"handleOnMaskChanged($event)\"\n [maskMode]=\"mode()\"\n inputmode=\"numeric\"\n class=\"ax-input\"\n [separator]=\"thousandsSeparator()\"\n [decimal]=\"decimals()\"\n [id]=\"id\"\n [attr.placeholder]=\"placeholder\"\n [attr.autocomplete]=\"'off'\"\n [class.ax-state-disabled]=\"disabled\"\n [class.ax-state-readonly]=\"readonly\"\n [disabled]=\"disabled\"\n [readonly]=\"readonly\"\n [tabindex]=\"tabIndex\"\n [(ngModel)]=\"stringValue\"\n (keydown)=\"handleOnKeydownEvent($event)\"\n (keyup)=\"emitOnKeyupEvent($event)\"\n (keypress)=\"emitOnKeypressEvent($event)\"\n (focus)=\"emitOnFocusEvent($event)\"\n (blur)=\"emitOnBlurEvent($event)\"\n (wheel)=\"onWheel($event)\"\n />\n @if (input.value && !disabled && !readonly) {\n <ng-content select=\"ax-clear-button\"></ng-content>\n }\n @if (showSpinButtons()) {\n <div class=\"ax-general-button-control\">\n <button\n type=\"button\"\n class=\"ax-general-button-icon\"\n [class.ax-state-disabled]=\"disabled\"\n (click)=\"handleUpClick()\"\n tabindex=\"-1\"\n [disabled]=\"disabled\"\n >\n <span class=\"ax-icon ax-icon-chevron-up ax-arrow-button\"></span>\n </button>\n <button\n type=\"button\"\n class=\"ax-general-button-icon\"\n [class.ax-state-disabled]=\"disabled\"\n (click)=\"handleDownClick()\"\n tabindex=\"-1\"\n [disabled]=\"disabled\"\n >\n <span class=\"ax-icon ax-icon-chevron-down ax-arrow-button\"></span>\n </button>\n </div>\n }\n\n <ng-content select=\"ax-suffix\"> </ng-content>\n</div>\n<ng-content select=\"ax-validation-rule\"> </ng-content>\n@if (minValue() != null || maxValue() != null) {\n <ax-validation-rule rule=\"callback\" [options]=\"{ validate: validateFn }\"></ax-validation-rule>\n}\n<div class=\"ax-error-container\"></div>\n", styles: ["@layer components{ax-number-box input::-webkit-outer-spin-button{-webkit-appearance:none;margin:calc(var(--spacing,.25rem) * 0)}ax-number-box input::-webkit-inner-spin-button{-webkit-appearance:none;margin:calc(var(--spacing,.25rem) * 0)}ax-number-box input[type=number]{-moz-appearance:textfield}ax-number-box .ax-general-button-control{flex-direction:column;width:fit-content;display:flex}ax-number-box .ax-general-button-control .ax-general-button-icon{height:calc(var(--spacing,.25rem) * 1)!important;padding:calc(var(--spacing,.25rem) * 1.5)!important;font-size:var(--text-xs,.75rem)!important;line-height:var(--tw-leading,var(--text-xs--line-height,calc(1 / .75)))!important}}\n/*! tailwindcss v4.3.0 | MIT License | https://tailwindcss.com */\n"] }]
|
|
204
242
|
}], propDecorators: { minValue: [{ type: i0.Input, args: [{ isSignal: true, alias: "minValue", required: false }] }], maxValue: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxValue", required: false }] }], showSpinButtons: [{ type: i0.Input, args: [{ isSignal: true, alias: "showSpinButtons", required: false }] }], thousandsSeparator: [{ type: i0.Input, args: [{ isSignal: true, alias: "thousandsSeparator", required: false }] }, { type: i0.Output, args: ["thousandsSeparatorChange"] }], decimals: [{ type: i0.Input, args: [{ isSignal: true, alias: "decimals", required: false }] }], changeOnScroll: [{ type: i0.Input, args: [{ isSignal: true, alias: "changeOnScroll", required: false }] }], step: [{ type: i0.Input, args: [{ isSignal: true, alias: "step", required: false }] }], input: [{ type: i0.ViewChild, args: ['input', { isSignal: true }] }], __hostName: [{
|
|
205
243
|
type: HostBinding,
|
|
206
244
|
args: ['attr.name']
|