@progress/kendo-angular-diagrams 19.3.0-develop.7

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.
@@ -0,0 +1,655 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2025 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { Component, ElementRef, EventEmitter, HostBinding, Input, NgZone, Output, Renderer2, } from '@angular/core';
6
+ import { Diagram } from '@progress/kendo-diagram-common';
7
+ import { validatePackage } from '@progress/kendo-licensing';
8
+ import { packageMetadata } from './package-metadata';
9
+ import { hasObservers, shouldShowValidationUI, WatermarkOverlayComponent } from '@progress/kendo-angular-common';
10
+ import { NgIf } from '@angular/common';
11
+ import { events, loadTheme } from '@progress/kendo-diagram-common';
12
+ import { CONNECTION_DEFAULTS, SHAPE_DEFAULTS } from './utils';
13
+ import * as i0 from "@angular/core";
14
+ /**
15
+ * Represents the [Kendo UI Diagram component for Angular({% slug overview_diagrams %}).
16
+ *
17
+ * The Diagram component is used to create organizational charts, and other types of diagrams.
18
+ *
19
+ * @example
20
+ * ```html
21
+ * <kendo-diagram [shapes]="shapesData"></kendo-diagram>
22
+ * ```
23
+ */
24
+ export class DiagramComponent {
25
+ wrapperElement;
26
+ renderer;
27
+ zone;
28
+ diagramClass = true;
29
+ /**
30
+ * Defines the default configuration options applicable to all connections.
31
+ * Changing the property value dynamically triggers a reinitialization of the Diagram.
32
+ */
33
+ connectionDefaults = CONNECTION_DEFAULTS;
34
+ /**
35
+ * Defines the connections that render between the shapes in the Diagram.
36
+ * Changing this property dynamically reinitializes the Diagram.
37
+ */
38
+ connections;
39
+ /**
40
+ * A set of settings to configure the Diagram behavior when the user attempts to drag, resize, or remove shapes.
41
+ * Changing the property value dynamically triggers a reinitialization of the Diagram.
42
+ * @default true
43
+ */
44
+ editable = { drag: true, resize: true, remove: true };
45
+ /**
46
+ * The layout of a diagram consists of arranging the shapes (sometimes also the connections) in some fashion in order to achieve an aesthetically pleasing experience to the user.
47
+ * Changing the property value dynamically triggers a reinitialization of the Diagram.
48
+ */
49
+ layout = { type: 'tree' };
50
+ /**
51
+ * Defines the pannable options. Use this setting to disable Diagram pan or change the key that activates the pan behavior.
52
+ * @default true
53
+ */
54
+ pannable = true;
55
+ /**
56
+ * Defines the Diagram selection options.
57
+ *
58
+ * By default, you can select shapes in the Diagram in one of two ways:
59
+ * - Clicking a single shape to select it and deselect any previously selected shapes.
60
+ * - Holding the `Ctrl/Cmd on MacOS` key while clicking multiple shapes to select them and any other shapes between them.
61
+ *
62
+ * Use the `selectable` configuration to allow single selection only, enable selection by drawing a rectangular area with the mouse around shapes in the canvas, or disable selection altogether.
63
+ * @default true
64
+ */
65
+ selectable = true;
66
+ /**
67
+ * Defines the default configuration options applicable to all shapes.
68
+ * Changing the property value dynamically triggers a reinitialization of the Diagram.
69
+ */
70
+ shapeDefaults = SHAPE_DEFAULTS;
71
+ /**
72
+ * Defines the shapes that render in the Diagram.
73
+ * Changing the property value dynamically triggers a reinitialization of the Diagram.
74
+ */
75
+ shapes;
76
+ /**
77
+ * Defines the zoom level of the Diagram.
78
+ *
79
+ * @default 1
80
+ */
81
+ zoom = 1;
82
+ /**
83
+ * Defines the maximum zoom level of the Diagram.
84
+ *
85
+ * @default 2
86
+ */
87
+ zoomMax = 2;
88
+ /**
89
+ * Defines the minimum zoom level of the Diagram.
90
+ *
91
+ * @default 0.1
92
+ */
93
+ zoomMin = 0.1;
94
+ /**
95
+ * Defines the zoom rate of the Diagram.
96
+ *
97
+ * @default 0.1
98
+ */
99
+ zoomRate = 0.1;
100
+ /**
101
+ * Fires when a shape or connection is created or removed.
102
+ */
103
+ change = new EventEmitter();
104
+ /**
105
+ * Fires when the user clicks on a shape or a connection.
106
+ */
107
+ diagramClick = new EventEmitter();
108
+ /**
109
+ * Fires when the user drags an item.
110
+ */
111
+ drag = new EventEmitter();
112
+ /**
113
+ * Fires when the user stops dragging an item.
114
+ */
115
+ dragEnd = new EventEmitter();
116
+ /**
117
+ * Fires when the user starts dragging an item.
118
+ */
119
+ dragStart = new EventEmitter();
120
+ /**
121
+ * Fires when the location or size of an item are changed.
122
+ */
123
+ shapeBoundsChange = new EventEmitter();
124
+ /**
125
+ * Fires when the mouse pointer enters a shape or connection.
126
+ */
127
+ mouseEnter = new EventEmitter();
128
+ /**
129
+ * Fires when the mouse pointer leaves a shape or connection.
130
+ */
131
+ mouseLeave = new EventEmitter();
132
+ /**
133
+ * Fires when the user pans the Diagram.
134
+ */
135
+ onPan = new EventEmitter();
136
+ /**
137
+ * Fires when the user selects one or more items.
138
+ */
139
+ onSelect = new EventEmitter();
140
+ /**
141
+ * Fires when the diagram has finished zooming out.
142
+ */
143
+ zoomEnd = new EventEmitter();
144
+ /**
145
+ * Fires when the diagram starts zooming in or out.
146
+ */
147
+ zoomStart = new EventEmitter();
148
+ /**
149
+ * @hidden
150
+ * Represents the Diagram instance, holding the core functionality of the Diagram.
151
+ */
152
+ diagram;
153
+ /**
154
+ * The currently selected items in the Diagram.
155
+ */
156
+ get selection() {
157
+ return this.diagram?.select();
158
+ }
159
+ /**
160
+ * The actual shapes created by the Diagram.
161
+ */
162
+ get diagramShapes() {
163
+ return this.diagram?.shapes;
164
+ }
165
+ /**
166
+ * The actual connections created by the Diagram.
167
+ */
168
+ get diagramConnections() {
169
+ return this.diagram?.connections;
170
+ }
171
+ /**
172
+ * @hidden
173
+ */
174
+ showLicenseWatermark = false;
175
+ options = {
176
+ shapes: this.shapes,
177
+ connections: this.connections,
178
+ selectable: this.selectable,
179
+ editable: this.editable,
180
+ zoom: this.zoom,
181
+ zoomMax: this.zoomMax,
182
+ zoomMin: this.zoomMin,
183
+ zoomRate: this.zoomRate,
184
+ shapeDefaults: this.shapeDefaults,
185
+ connectionDefaults: this.connectionDefaults,
186
+ layout: this.layout,
187
+ };
188
+ constructor(wrapperElement, renderer, zone) {
189
+ this.wrapperElement = wrapperElement;
190
+ this.renderer = renderer;
191
+ this.zone = zone;
192
+ const isValid = validatePackage(packageMetadata);
193
+ this.showLicenseWatermark = shouldShowValidationUI(isValid);
194
+ }
195
+ ngOnChanges(changes) {
196
+ let recreate = false;
197
+ if (changes['shapes']) {
198
+ this.options.shapes = this.shapes;
199
+ recreate = true;
200
+ }
201
+ if (changes['connections']) {
202
+ this.options.connections = this.connections;
203
+ recreate = true;
204
+ }
205
+ if (changes['connectionDefaults']) {
206
+ this.options.connectionDefaults = { ...this.options.connectionDefaults, ...this.connectionDefaults };
207
+ recreate = true;
208
+ }
209
+ if (changes['shapeDefaults']) {
210
+ this.options.shapeDefaults = { ...this.options.shapeDefaults, ...this.shapeDefaults };
211
+ recreate = true;
212
+ }
213
+ if (changes['editable'] && this.editable || typeof this.editable === 'boolean') {
214
+ if (typeof this.editable === 'boolean') {
215
+ if (this.editable) {
216
+ this.options.editable = { drag: true, resize: true, remove: true };
217
+ this.options.shapeDefaults.editable = { drag: true, remove: true };
218
+ }
219
+ else {
220
+ this.options.editable = { drag: false, resize: false, remove: false };
221
+ this.options.shapeDefaults.editable = { drag: false, remove: false };
222
+ }
223
+ }
224
+ if (typeof this.editable === 'object') {
225
+ this.options.editable = {
226
+ drag: this.editable.drag,
227
+ resize: this.editable.resize,
228
+ remove: this.editable.remove
229
+ };
230
+ this.options.shapeDefaults.editable = { drag: this.editable.drag, remove: this.editable.remove };
231
+ }
232
+ recreate = true;
233
+ }
234
+ if (changes['zoomMax']) {
235
+ this.updateOptions('zoomMax');
236
+ }
237
+ if (changes['zoomMin']) {
238
+ this.updateOptions('zoomMin');
239
+ }
240
+ if (changes['zoomRate']) {
241
+ this.updateOptions('zoomRate');
242
+ }
243
+ if (changes['selectable']) {
244
+ this.updateOptions('selectable');
245
+ }
246
+ if (changes['layout']) {
247
+ this.updateOptions('layout');
248
+ this.diagram?.layout(this.options.layout);
249
+ }
250
+ if (changes['pannable']) {
251
+ this.updateOptions('pannable');
252
+ }
253
+ if (changes['zoom']) {
254
+ this.updateOptions('zoom');
255
+ this.diagram?.zoom(this.diagram.options.zoom);
256
+ }
257
+ if (recreate) {
258
+ this.init();
259
+ }
260
+ }
261
+ ngAfterViewInit() {
262
+ this.renderer.setStyle(this.wrapperElement.nativeElement, 'display', 'block');
263
+ this.init();
264
+ events.forEach((eventName) => {
265
+ this.diagram.bind(eventName, (e) => {
266
+ if (eventName === 'click') {
267
+ eventName = 'diagramClick';
268
+ }
269
+ if (eventName === 'select') {
270
+ eventName = 'onSelect';
271
+ }
272
+ if (eventName === 'pan') {
273
+ eventName = 'onPan';
274
+ }
275
+ if (eventName === 'itemBoundsChange') {
276
+ eventName = 'shapeBoundsChange';
277
+ }
278
+ const emitter = this.activeEmitter(eventName);
279
+ if (emitter) {
280
+ this.zone.run(() => {
281
+ emitter.emit(e);
282
+ });
283
+ }
284
+ });
285
+ });
286
+ }
287
+ ngOnDestroy() {
288
+ this.diagram?.destroy();
289
+ }
290
+ /**
291
+ * Provides the current Diagram's shapes and connections that can be used to create a new Diagram when needed.
292
+ * @returns {DiagramState} Object containing shapes and connections arrays.
293
+ */
294
+ getState() {
295
+ return this.diagram?.save();
296
+ }
297
+ /**
298
+ * Focuses the Diagram.
299
+ * @returns {boolean} true if focus was set successfully.
300
+ */
301
+ focus() {
302
+ return this.diagram?.focus();
303
+ }
304
+ /**
305
+ * Clears the Diagram.
306
+ */
307
+ clear() {
308
+ this.diagram?.clear();
309
+ }
310
+ /**
311
+ * Determines whether two shapes are connected.
312
+ * @param {Shape} Shape.
313
+ * @param {Shape} Shape.
314
+ * @returns {boolean} true if the two shapes are connected.
315
+ */
316
+ connected(source, target) {
317
+ return this.diagram?.connected(source, target);
318
+ }
319
+ /**
320
+ * Adds connection to the Diagram.
321
+ * @param {Connection} Connection.
322
+ * @param {boolean} Boolean.
323
+ * @returns {Connection} The newly created connection.
324
+ */
325
+ addConnection(connection, undoable) {
326
+ const newConnection = this.diagram?.addConnection(connection, undoable);
327
+ return newConnection;
328
+ }
329
+ /**
330
+ * Adds shape to the Diagram.
331
+ * @param {ShapeOptions | Shape | Point} If you pass a `Point`, a new Shape with default options will be created and positioned at that point.
332
+ * @param {boolean} Boolean indicating if the action should be undoable.
333
+ * @returns {Shape} The newly created shape.
334
+ */
335
+ addShape(item, undoable) {
336
+ const newShape = this.diagram?.addShape(item, undoable);
337
+ return newShape;
338
+ }
339
+ /**
340
+ * Removes shape(s) and/or connection(s) from the Diagram.
341
+ * @param {Shape | Connection | (Shape | Connection)[]} Shape, Connection or an Array of Shapes and/or Connections.
342
+ * @param {Boolean} Boolean indicating if the action should be undoable.
343
+ */
344
+ remove(items, undoable) {
345
+ this.diagram?.remove(items, undoable);
346
+ }
347
+ /**
348
+ * Connects two items in the Diagram.
349
+ * @param {Shape | Connector | Point} Shape, Shape's Connector or Point.
350
+ * @param {Shape | Connector | Point} Shape, Shape's Connector or Point.
351
+ * @param {ConnectionOptions} Connection options.
352
+ * @returns {Connection} The created connection.
353
+ */
354
+ connect(source, target, options) {
355
+ return this.diagram?.connect(source, target, options);
356
+ }
357
+ /**
358
+ * Executes the next undoable action on top of the undo stack if any.
359
+ */
360
+ undo() {
361
+ this.diagram?.undo();
362
+ }
363
+ /**
364
+ * Executes the previous undoable action on top of the redo stack if any.
365
+ */
366
+ redo() {
367
+ this.diagram?.redo();
368
+ }
369
+ /**
370
+ * Selects items on the basis of the given input.
371
+ * @param {Shape | Connection | (Shape | Connection)[]} Shape, Connection or an Array of Shapes and/or Connections.
372
+ * @param Selection options.
373
+ * @returns {(Shape | Connection)[]} Array of selected items.
374
+ */
375
+ select(items, options) {
376
+ return this.diagram?.select(items, options);
377
+ }
378
+ /**
379
+ * Selects all items in the Diagram.
380
+ */
381
+ selectAll() {
382
+ this.diagram?.selectAll();
383
+ }
384
+ /**
385
+ * Selects items in the specified area.
386
+ * @param {Rect} rect Rectangle area to select.
387
+ */
388
+ selectArea(rect) {
389
+ this.diagram?.selectArea(rect);
390
+ }
391
+ /**
392
+ * Deselects the specified items or all items if no item is specified.
393
+ * @param {Shape | Connection | (Shape | Connection)[]} Shape, Connection or an Array of Shapes and/or Connections.
394
+ */
395
+ deselect(items) {
396
+ this.diagram?.deselect(items);
397
+ }
398
+ /**
399
+ * Brings to front the passed items.
400
+ * @param {Shape | Connection | (Shape | Connection)[]} Shape, Connection or an Array of Shapes and/or Connections.
401
+ * @param {boolean} By default the action is undoable.
402
+ */
403
+ bringToFront(items, undoable) {
404
+ this.diagram?.toFront(items, undoable);
405
+ }
406
+ /**
407
+ * Sends to back the passed items.
408
+ * @param {Shape | Connection | (Shape | Connection)[]} Shape, Connection or an Array of Shapes and/or Connections.
409
+ * @param {boolean} By default the action is undoable.
410
+ */
411
+ bringToBack(items, undoable) {
412
+ this.diagram?.toBack(items, undoable);
413
+ }
414
+ /**
415
+ * Bring into view the passed item(s) or rectangle.
416
+ * @param {Shape | Connection | (Shape | Connection)[]} Shape, Connection or an Array of Shapes and/or Connections.
417
+ * @param {DiagramAlignOptions} controls the position of the calculated rectangle relative to the viewport.
418
+ * "Center middle" will position the items in the center. animate - controls if the pan should be animated.
419
+ */
420
+ bringIntoView(item, options) {
421
+ this.diagram?.bringIntoView(item, options);
422
+ }
423
+ /**
424
+ * Aligns shapes in the specified direction.
425
+ * @param {Direction} Direction to align shapes.
426
+ */
427
+ alignShapes(direction) {
428
+ this.diagram?.alignShapes(direction);
429
+ }
430
+ /**
431
+ * @hidden
432
+ * Pans the Diagram.
433
+ * @param {Point} Pan coordinates.
434
+ * @param {boolean} Whether to animate the pan.
435
+ * @returns {Point} Current pan position.
436
+ */
437
+ pan(pan, animate) {
438
+ return this.diagram?.pan(pan, animate);
439
+ }
440
+ /**
441
+ * Gets the current `Diagram` viewport rectangle.
442
+ * @returns {Rect} Viewport rectangle.
443
+ */
444
+ viewport() {
445
+ return this.diagram?.viewport();
446
+ }
447
+ /**
448
+ * Copies selected items to clipboard.
449
+ */
450
+ copy() {
451
+ this.diagram?.copy();
452
+ }
453
+ /**
454
+ * @hidden
455
+ * Cuts selected items to clipboard.
456
+ */
457
+ cut() {
458
+ this.diagram?.cut();
459
+ }
460
+ /**
461
+ * Pastes items from clipboard.
462
+ */
463
+ paste() {
464
+ this.diagram?.paste();
465
+ }
466
+ /**
467
+ * Gets the bounding rectangle of the given items.
468
+ * @param {Shape | Connection | (Shape | Connection)[]} Shape, Connection or an Array of Shapes and/or Connections.
469
+ * @param {boolean} Pass 'true' if you need to get the bounding box of the shapes without their rotation offset.
470
+ * @returns {Rect} Bounding rectangle.
471
+ */
472
+ boundingBox(items, origin) {
473
+ return this.diagram?.boundingBox(items, origin);
474
+ }
475
+ /**
476
+ * Converts document coordinates to view coordinates.
477
+ * @param {Point} Point in document coordinates.
478
+ * @returns {Point} Point in view coordinates.
479
+ */
480
+ documentToView(point) {
481
+ return this.diagram?.documentToView(point);
482
+ }
483
+ /**
484
+ * Converts view coordinates to document coordinates.
485
+ * @param {Point} Point in view coordinates.
486
+ * @returns {Point} Point in document coordinates.
487
+ */
488
+ viewToDocument(point) {
489
+ return this.diagram?.viewToDocument(point);
490
+ }
491
+ /**
492
+ * Converts view coordinates to model coordinates.
493
+ * @param {Point} Point in view coordinates.
494
+ * @returns {Point} Point in model coordinates.
495
+ */
496
+ viewToModel(point) {
497
+ return this.diagram?.viewToModel(point);
498
+ }
499
+ /**
500
+ * Converts model coordinates to view coordinates.
501
+ * @param {Point} Point in model coordinates.
502
+ * @returns {Point} Point in view coordinates.
503
+ */
504
+ modelToView(point) {
505
+ return this.diagram?.modelToView(point);
506
+ }
507
+ /**
508
+ * Converts model coordinates to layer coordinates.
509
+ * @param {Point} Point in model coordinates.
510
+ * @returns {Point} Point in layer coordinates.
511
+ */
512
+ modelToLayer(point) {
513
+ return this.diagram?.modelToLayer(point);
514
+ }
515
+ /**
516
+ * Converts layer coordinates to model coordinates.
517
+ * @param {Point} Point in layer coordinates.
518
+ * @returns {Point} Point in model coordinates.
519
+ */
520
+ layerToModel(point) {
521
+ return this.diagram?.layerToModel(point);
522
+ }
523
+ /**
524
+ * Converts document coordinates to model coordinates.
525
+ * @param {Point} Point in document coordinates.
526
+ * @returns {Point} Point in model coordinates.
527
+ */
528
+ documentToModel(point) {
529
+ return this.diagram?.documentToModel(point);
530
+ }
531
+ /**
532
+ * Converts model coordinates to document coordinates.
533
+ * @param {Point} Point in model coordinates.
534
+ * @returns {Point} Point in document coordinates.
535
+ */
536
+ modelToDocument(point) {
537
+ return this.diagram?.modelToDocument(point);
538
+ }
539
+ /**
540
+ * Gets a shape on the basis of its identifier.
541
+ * @param {string} The identifier of a shape.
542
+ * @returns {Shape} The shape with the specified ID.
543
+ */
544
+ getShapeById(id) {
545
+ return this.diagram?.getShapeById(id);
546
+ }
547
+ /**
548
+ * Exports the diagram's DOM visual representation for rendering or export purposes.
549
+ * Creates a clipped group containing the canvas content with proper transformations.
550
+ * @returns {Group} A drawing Group element containing the exported DOM visual
551
+ */
552
+ exportDOMVisual() {
553
+ return this.diagram?.exportDOMVisual();
554
+ }
555
+ /**
556
+ * Exports the diagram's visual representation with proper scaling based on zoom level.
557
+ * Creates a scaled group containing the main layer content.
558
+ * @returns {Group} A drawing Group element containing the exported visual with inverse zoom scaling
559
+ */
560
+ exportVisual() {
561
+ return this.diagram?.exportVisual();
562
+ }
563
+ activeEmitter(name) {
564
+ const emitter = this[name];
565
+ if (emitter?.emit && hasObservers(emitter)) {
566
+ return emitter;
567
+ }
568
+ }
569
+ init() {
570
+ if (this.diagram) {
571
+ this.diagram.destroy();
572
+ }
573
+ this.zone.runOutsideAngular(() => {
574
+ const theme = loadTheme(this.wrapperElement.nativeElement);
575
+ this.diagram = new Diagram(this.wrapperElement.nativeElement, this.options, theme);
576
+ this.diagram._createOptionElements();
577
+ this.diagram.zoom(this.diagram.options.zoom);
578
+ this.diagram.canvas.draw();
579
+ this.diagram.bringIntoView(this.diagram.shapes);
580
+ });
581
+ }
582
+ updateOptions(prop) {
583
+ this.options[prop] = this[prop];
584
+ this.diagram?.setOptions(this.options);
585
+ }
586
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DiagramComponent, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component });
587
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: DiagramComponent, isStandalone: true, selector: "kendo-diagram", inputs: { connectionDefaults: "connectionDefaults", connections: "connections", editable: "editable", layout: "layout", pannable: "pannable", selectable: "selectable", shapeDefaults: "shapeDefaults", shapes: "shapes", zoom: "zoom", zoomMax: "zoomMax", zoomMin: "zoomMin", zoomRate: "zoomRate" }, outputs: { change: "change", diagramClick: "diagramClick", drag: "drag", dragEnd: "dragEnd", dragStart: "dragStart", shapeBoundsChange: "shapeBoundsChange", mouseEnter: "mouseEnter", mouseLeave: "mouseLeave", onPan: "pan", onSelect: "select", zoomEnd: "zoomEnd", zoomStart: "zoomStart" }, host: { properties: { "class.k-diagram": "this.diagramClass" } }, exportAs: ["kendoDiagram"], usesOnChanges: true, ngImport: i0, template: `
588
+ <div kendoWatermarkOverlay *ngIf="showLicenseWatermark"></div>
589
+ `, isInline: true, dependencies: [{ kind: "component", type: WatermarkOverlayComponent, selector: "div[kendoWatermarkOverlay]" }, { kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
590
+ }
591
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DiagramComponent, decorators: [{
592
+ type: Component,
593
+ args: [{
594
+ standalone: true,
595
+ exportAs: 'kendoDiagram',
596
+ selector: 'kendo-diagram',
597
+ template: `
598
+ <div kendoWatermarkOverlay *ngIf="showLicenseWatermark"></div>
599
+ `,
600
+ imports: [WatermarkOverlayComponent, NgIf]
601
+ }]
602
+ }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i0.Renderer2 }, { type: i0.NgZone }]; }, propDecorators: { diagramClass: [{
603
+ type: HostBinding,
604
+ args: ['class.k-diagram']
605
+ }], connectionDefaults: [{
606
+ type: Input
607
+ }], connections: [{
608
+ type: Input
609
+ }], editable: [{
610
+ type: Input
611
+ }], layout: [{
612
+ type: Input
613
+ }], pannable: [{
614
+ type: Input
615
+ }], selectable: [{
616
+ type: Input
617
+ }], shapeDefaults: [{
618
+ type: Input
619
+ }], shapes: [{
620
+ type: Input
621
+ }], zoom: [{
622
+ type: Input
623
+ }], zoomMax: [{
624
+ type: Input
625
+ }], zoomMin: [{
626
+ type: Input
627
+ }], zoomRate: [{
628
+ type: Input
629
+ }], change: [{
630
+ type: Output
631
+ }], diagramClick: [{
632
+ type: Output
633
+ }], drag: [{
634
+ type: Output
635
+ }], dragEnd: [{
636
+ type: Output
637
+ }], dragStart: [{
638
+ type: Output
639
+ }], shapeBoundsChange: [{
640
+ type: Output
641
+ }], mouseEnter: [{
642
+ type: Output
643
+ }], mouseLeave: [{
644
+ type: Output
645
+ }], onPan: [{
646
+ type: Output,
647
+ args: ['pan']
648
+ }], onSelect: [{
649
+ type: Output,
650
+ args: ['select']
651
+ }], zoomEnd: [{
652
+ type: Output
653
+ }], zoomStart: [{
654
+ type: Output
655
+ }] } });
@@ -0,0 +1,51 @@
1
+ /**-----------------------------------------------------------------------------------------
2
+ * Copyright © 2025 Progress Software Corporation. All rights reserved.
3
+ * Licensed under commercial license. See LICENSE.md in the project root for more information
4
+ *-------------------------------------------------------------------------------------------*/
5
+ import { NgModule } from '@angular/core';
6
+ import { KENDO_DIAGRAM } from './directives';
7
+ import * as i0 from "@angular/core";
8
+ import * as i1 from "./diagram.component";
9
+ /**
10
+ * Represents the [NgModule](link:site.data.urls.angular['ngmoduleapi'])
11
+ * definition for the Diagram component.
12
+ *
13
+ * @example
14
+ *
15
+ * ```ts-no-run
16
+ * // Import the Diagram module
17
+ * import { DiagramModule } from '@progress/kendo-angular-diagrams';
18
+ *
19
+ * // The browser platform with a compiler
20
+ * import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
21
+ *
22
+ * import { NgModule } from '@angular/core';
23
+ *
24
+ * // Import the app component
25
+ * import { AppComponent } from './app.component';
26
+ *
27
+ * // Define the app module
28
+ * _@NgModule({
29
+ * declarations: [AppComponent],
30
+ * imports: [BrowserModule, DiagramModule],
31
+ * bootstrap: [AppComponent]
32
+ * })
33
+ * export class AppModule {}
34
+ *
35
+ * // Compile and launch the module
36
+ * platformBrowserDynamic().bootstrapModule(AppModule);
37
+ *
38
+ * ```
39
+ */
40
+ export class DiagramModule {
41
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DiagramModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
42
+ static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: DiagramModule, imports: [i1.DiagramComponent], exports: [i1.DiagramComponent] });
43
+ static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DiagramModule, imports: [KENDO_DIAGRAM] });
44
+ }
45
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DiagramModule, decorators: [{
46
+ type: NgModule,
47
+ args: [{
48
+ imports: [...KENDO_DIAGRAM],
49
+ exports: [...KENDO_DIAGRAM]
50
+ }]
51
+ }] });