bpmn-js 13.0.0 → 13.0.2
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/dist/bpmn-modeler.development.js +39 -20
- package/dist/bpmn-modeler.production.min.js +1 -1
- package/dist/bpmn-navigated-viewer.development.js +12 -7
- package/dist/bpmn-navigated-viewer.production.min.js +1 -1
- package/dist/bpmn-viewer.development.js +12 -7
- package/dist/bpmn-viewer.production.min.js +1 -1
- package/lib/BaseModeler.d.ts +12 -12
- package/lib/BaseViewer.d.ts +160 -160
- package/lib/Modeler.d.ts +76 -76
- package/lib/NavigatedViewer.d.ts +8 -8
- package/lib/Viewer.d.ts +44 -44
- package/lib/core/index.d.ts +10 -10
- package/lib/draw/BpmnRenderUtil.d.ts +77 -76
- package/lib/draw/BpmnRenderUtil.js +4 -3
- package/lib/draw/BpmnRenderer.d.ts +124 -124
- package/lib/draw/PathMap.d.ts +330 -330
- package/lib/draw/TextRenderer.d.ts +74 -74
- package/lib/draw/index.d.ts +10 -10
- package/lib/features/align-elements/AlignElementsContextPadProvider.d.ts +32 -32
- package/lib/features/align-elements/AlignElementsIcons.d.ts +10 -10
- package/lib/features/align-elements/AlignElementsMenuProvider.d.ts +32 -32
- package/lib/features/align-elements/BpmnAlignElements.d.ts +9 -9
- package/lib/features/align-elements/index.d.ts +11 -11
- package/lib/features/auto-place/BpmnAutoPlace.d.ts +13 -13
- package/lib/features/auto-place/BpmnAutoPlaceUtil.d.ts +47 -47
- package/lib/features/auto-place/index.d.ts +7 -7
- package/lib/features/auto-resize/BpmnAutoResize.d.ts +25 -25
- package/lib/features/auto-resize/BpmnAutoResizeProvider.d.ts +26 -26
- package/lib/features/auto-resize/index.d.ts +8 -8
- package/lib/features/context-pad/ContextPadProvider.d.ts +60 -60
- package/lib/features/context-pad/index.d.ts +7 -7
- package/lib/features/copy-paste/BpmnCopyPaste.d.ts +17 -17
- package/lib/features/copy-paste/ModdleCopy.d.ts +45 -45
- package/lib/features/copy-paste/index.d.ts +9 -9
- package/lib/features/di-ordering/BpmnDiOrdering.d.ts +11 -11
- package/lib/features/di-ordering/index.d.ts +6 -6
- package/lib/features/distribute-elements/BpmnDistributeElements.d.ts +10 -10
- package/lib/features/distribute-elements/DistributeElementsIcons.d.ts +5 -5
- package/lib/features/distribute-elements/DistributeElementsMenuProvider.d.ts +32 -32
- package/lib/features/distribute-elements/index.d.ts +9 -9
- package/lib/features/drilldown/DrilldownBreadcrumbs.d.ts +19 -19
- package/lib/features/drilldown/DrilldownCentering.d.ts +17 -17
- package/lib/features/drilldown/DrilldownOverlayBehavior.d.ts +18 -18
- package/lib/features/drilldown/SubprocessCompatibility.d.ts +21 -21
- package/lib/features/drilldown/index.d.ts +13 -13
- package/lib/features/editor-actions/BpmnEditorActions.d.ts +13 -13
- package/lib/features/editor-actions/index.d.ts +6 -6
- package/lib/features/grid-snapping/BpmnGridSnapping.d.ts +9 -9
- package/lib/features/grid-snapping/behavior/GridSnappingAutoPlaceBehavior.d.ts +12 -12
- package/lib/features/grid-snapping/behavior/GridSnappingLayoutConnectionBehavior.d.ts +27 -27
- package/lib/features/grid-snapping/behavior/GridSnappingParticipantBehavior.d.ts +13 -13
- package/lib/features/grid-snapping/behavior/index.d.ts +10 -10
- package/lib/features/grid-snapping/index.d.ts +11 -11
- package/lib/features/interaction-events/BpmnInteractionEvents.d.ts +18 -18
- package/lib/features/interaction-events/index.d.ts +6 -6
- package/lib/features/keyboard/BpmnKeyboardBindings.d.ts +15 -15
- package/lib/features/keyboard/index.d.ts +7 -7
- package/lib/features/label-editing/LabelEditingPreview.d.ts +13 -13
- package/lib/features/label-editing/LabelEditingProvider.d.ts +62 -62
- package/lib/features/label-editing/LabelUtil.d.ts +14 -14
- package/lib/features/label-editing/cmd/UpdateLabelHandler.d.ts +22 -22
- package/lib/features/label-editing/index.d.ts +9 -9
- package/lib/features/modeling/BpmnFactory.d.ts +73 -67
- package/lib/features/modeling/BpmnFactory.js +7 -3
- package/lib/features/modeling/BpmnLayouter.d.ts +26 -26
- package/lib/features/modeling/BpmnUpdater.d.ts +92 -92
- package/lib/features/modeling/ElementFactory.d.ts +119 -116
- package/lib/features/modeling/ElementFactory.js +5 -5
- package/lib/features/modeling/Modeling.d.ts +150 -150
- package/lib/features/modeling/behavior/AdaptiveLabelPositioningBehavior.d.ts +20 -20
- package/lib/features/modeling/behavior/AppendBehavior.d.ts +6 -6
- package/lib/features/modeling/behavior/AssociationBehavior.d.ts +11 -11
- package/lib/features/modeling/behavior/AttachEventBehavior.d.ts +15 -15
- package/lib/features/modeling/behavior/BoundaryEventBehavior.d.ts +15 -15
- package/lib/features/modeling/behavior/CreateBehavior.d.ts +9 -9
- package/lib/features/modeling/behavior/CreateDataObjectBehavior.d.ts +15 -15
- package/lib/features/modeling/behavior/CreateParticipantBehavior.d.ts +19 -19
- package/lib/features/modeling/behavior/DataInputAssociationBehavior.d.ts +21 -21
- package/lib/features/modeling/behavior/DataStoreBehavior.d.ts +19 -19
- package/lib/features/modeling/behavior/DeleteLaneBehavior.d.ts +15 -15
- package/lib/features/modeling/behavior/DetachEventBehavior.d.ts +15 -15
- package/lib/features/modeling/behavior/DropOnFlowBehavior.d.ts +13 -13
- package/lib/features/modeling/behavior/EventBasedGatewayBehavior.d.ts +11 -11
- package/lib/features/modeling/behavior/FixHoverBehavior.d.ts +17 -17
- package/lib/features/modeling/behavior/GroupBehavior.d.ts +26 -26
- package/lib/features/modeling/behavior/ImportDockingFix.d.ts +13 -13
- package/lib/features/modeling/behavior/IsHorizontalFix.d.ts +10 -10
- package/lib/features/modeling/behavior/LabelBehavior.d.ts +56 -56
- package/lib/features/modeling/behavior/LayoutConnectionBehavior.d.ts +16 -16
- package/lib/features/modeling/behavior/MessageFlowBehavior.d.ts +15 -15
- package/lib/features/modeling/behavior/ModelingFeedback.d.ts +13 -13
- package/lib/features/modeling/behavior/RemoveElementBehavior.d.ts +13 -13
- package/lib/features/modeling/behavior/RemoveEmbeddedLabelBoundsBehavior.d.ts +16 -16
- package/lib/features/modeling/behavior/RemoveParticipantBehavior.d.ts +15 -15
- package/lib/features/modeling/behavior/ReplaceConnectionBehavior.d.ts +15 -15
- package/lib/features/modeling/behavior/ReplaceElementBehaviour.d.ts +23 -23
- package/lib/features/modeling/behavior/ResizeBehavior.d.ts +57 -57
- package/lib/features/modeling/behavior/ResizeLaneBehavior.d.ts +16 -16
- package/lib/features/modeling/behavior/RootElementReferenceBehavior.d.ts +25 -25
- package/lib/features/modeling/behavior/SpaceToolBehavior.d.ts +10 -10
- package/lib/features/modeling/behavior/SubProcessPlaneBehavior.d.ts +28 -28
- package/lib/features/modeling/behavior/SubProcessStartEventBehavior.d.ts +15 -15
- package/lib/features/modeling/behavior/ToggleCollapseConnectionBehaviour.d.ts +14 -14
- package/lib/features/modeling/behavior/ToggleElementCollapseBehaviour.d.ts +13 -13
- package/lib/features/modeling/behavior/UnclaimIdBehavior.d.ts +19 -19
- package/lib/features/modeling/behavior/UnsetDefaultFlowBehavior.d.ts +16 -16
- package/lib/features/modeling/behavior/UpdateFlowNodeRefsBehavior.d.ts +17 -17
- package/lib/features/modeling/behavior/index.d.ts +2 -2
- package/lib/features/modeling/behavior/util/CategoryUtil.d.ts +49 -49
- package/lib/features/modeling/behavior/util/ConnectionLayoutUtil.d.ts +19 -19
- package/lib/features/modeling/behavior/util/GeometricUtil.d.ts +1 -1
- package/lib/features/modeling/behavior/util/LabelLayoutUtil.d.ts +32 -32
- package/lib/features/modeling/behavior/util/LayoutUtil.d.ts +48 -48
- package/lib/features/modeling/behavior/util/LineAttachmentUtil.d.ts +37 -37
- package/lib/features/modeling/behavior/util/LineIntersect.d.ts +13 -13
- package/lib/features/modeling/behavior/util/ResizeUtil.d.ts +1 -1
- package/lib/features/modeling/cmd/AddLaneHandler.d.ts +22 -22
- package/lib/features/modeling/cmd/IdClaimHandler.d.ts +22 -22
- package/lib/features/modeling/cmd/ResizeLaneHandler.d.ts +39 -39
- package/lib/features/modeling/cmd/SetColorHandler.d.ts +18 -18
- package/lib/features/modeling/cmd/SplitLaneHandler.d.ts +22 -22
- package/lib/features/modeling/cmd/UpdateCanvasRootHandler.d.ts +20 -20
- package/lib/features/modeling/cmd/UpdateFlowNodeRefsHandler.d.ts +21 -21
- package/lib/features/modeling/cmd/UpdateModdlePropertiesHandler.d.ts +20 -20
- package/lib/features/modeling/cmd/UpdatePropertiesHandler.d.ts +60 -60
- package/lib/features/modeling/cmd/UpdateSemanticParentHandler.d.ts +18 -18
- package/lib/features/modeling/index.d.ts +27 -27
- package/lib/features/modeling/util/LaneUtil.d.ts +46 -46
- package/lib/features/modeling/util/ModelingUtil.d.ts +12 -12
- package/lib/features/ordering/BpmnOrderingProvider.d.ts +21 -21
- package/lib/features/ordering/index.d.ts +7 -7
- package/lib/features/palette/PaletteProvider.d.ts +34 -34
- package/lib/features/palette/index.d.ts +9 -9
- package/lib/features/popup-menu/ReplaceMenuProvider.d.ts +50 -50
- package/lib/features/popup-menu/ReplaceMenuProvider.js +1 -1
- package/lib/features/popup-menu/index.d.ts +11 -11
- package/lib/features/popup-menu/util/TypeUtil.d.ts +14 -12
- package/lib/features/popup-menu/util/TypeUtil.js +5 -2
- package/lib/features/replace/BpmnReplace.d.ts +47 -47
- package/lib/features/replace/ReplaceOptions.d.ts +75 -70
- package/lib/features/replace/ReplaceOptions.js +9 -3
- package/lib/features/replace/index.d.ts +9 -9
- package/lib/features/replace-preview/BpmnReplacePreview.d.ts +17 -17
- package/lib/features/replace-preview/index.d.ts +7 -7
- package/lib/features/rules/BpmnRules.d.ts +172 -171
- package/lib/features/rules/BpmnRules.js +3 -2
- package/lib/features/rules/index.d.ts +7 -7
- package/lib/features/search/BpmnSearchProvider.d.ts +29 -29
- package/lib/features/search/index.d.ts +7 -7
- package/lib/features/snapping/BpmnConnectSnapping.d.ts +17 -17
- package/lib/features/snapping/BpmnCreateMoveSnapping.d.ts +41 -41
- package/lib/features/snapping/BpmnSnappingUtil.d.ts +11 -11
- package/lib/features/snapping/index.d.ts +9 -9
- package/lib/features/space-tool/BpmnSpaceTool.d.ts +21 -21
- package/lib/features/space-tool/index.d.ts +6 -6
- package/lib/icons/dist/append.svg +1 -0
- package/lib/icons/dist/connect-context-pad.svg +1 -0
- package/lib/icons/dist/connect-palette.svg +1 -0
- package/lib/icons/dist/create.svg +1 -0
- package/lib/import/BpmnImporter.d.ts +53 -49
- package/lib/import/BpmnImporter.js +5 -1
- package/lib/import/BpmnTreeWalker.d.ts +22 -22
- package/lib/import/BpmnTreeWalker.js +3 -3
- package/lib/import/Importer.d.ts +25 -25
- package/lib/import/Importer.js +1 -1
- package/lib/import/Util.d.ts +1 -1
- package/lib/import/index.d.ts +6 -6
- package/lib/model/Types.d.ts +24 -24
- package/lib/model/Types.ts +1 -1
- package/lib/util/CompatibilityUtil.d.ts +22 -22
- package/lib/util/DiUtil.d.ts +53 -53
- package/lib/util/DiUtil.js +1 -1
- package/lib/util/DrilldownUtil.d.ts +39 -39
- package/lib/util/LabelUtil.d.ts +73 -73
- package/lib/util/ModelUtil.d.ts +40 -40
- package/lib/util/PoweredByUtil.d.ts +8 -8
- package/package.json +2 -2
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* bpmn-js - bpmn-modeler v13.0.
|
|
2
|
+
* bpmn-js - bpmn-modeler v13.0.2
|
|
3
3
|
*
|
|
4
4
|
* Copyright (c) 2014-present, camunda Services GmbH
|
|
5
5
|
*
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
*
|
|
9
9
|
* Source Code: https://github.com/bpmn-io/bpmn-js
|
|
10
10
|
*
|
|
11
|
-
* Date: 2023-04-
|
|
11
|
+
* Date: 2023-04-20
|
|
12
12
|
*/
|
|
13
13
|
(function (global, factory) {
|
|
14
14
|
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
|
|
@@ -16071,7 +16071,7 @@
|
|
|
16071
16071
|
* Find a suitable display candidate for definitions where the DI does not
|
|
16072
16072
|
* correctly specify one.
|
|
16073
16073
|
*
|
|
16074
|
-
* @param {ModdleElement}
|
|
16074
|
+
* @param {ModdleElement} definitions
|
|
16075
16075
|
*
|
|
16076
16076
|
* @return {ModdleElement}
|
|
16077
16077
|
*/
|
|
@@ -16082,7 +16082,7 @@
|
|
|
16082
16082
|
}
|
|
16083
16083
|
|
|
16084
16084
|
/**
|
|
16085
|
-
* @param {Function} handler
|
|
16085
|
+
* @param {Record<'element' | 'root' | 'error', Function>} handler
|
|
16086
16086
|
* @param {Translate} translate
|
|
16087
16087
|
*/
|
|
16088
16088
|
function BpmnTreeWalker(handler, translate) {
|
|
@@ -17772,7 +17772,7 @@
|
|
|
17772
17772
|
|
|
17773
17773
|
/**
|
|
17774
17774
|
* @param {Element} element
|
|
17775
|
-
* @param {ModdleElement} di
|
|
17775
|
+
* @param {ModdleElement} [di]
|
|
17776
17776
|
*
|
|
17777
17777
|
* @return {boolean}
|
|
17778
17778
|
*/
|
|
@@ -17986,7 +17986,7 @@
|
|
|
17986
17986
|
|
|
17987
17987
|
/**
|
|
17988
17988
|
* @param {DiagramElement} element
|
|
17989
|
-
* @param {string} defaultColor
|
|
17989
|
+
* @param {string} [defaultColor]
|
|
17990
17990
|
*
|
|
17991
17991
|
* @return {string}
|
|
17992
17992
|
*/
|
|
@@ -17998,7 +17998,7 @@
|
|
|
17998
17998
|
|
|
17999
17999
|
/**
|
|
18000
18000
|
* @param {DiagramElement} element
|
|
18001
|
-
* @param {string} defaultColor
|
|
18001
|
+
* @param {string} [defaultColor]
|
|
18002
18002
|
*
|
|
18003
18003
|
* @return {string}
|
|
18004
18004
|
*/
|
|
@@ -18049,6 +18049,7 @@
|
|
|
18049
18049
|
|
|
18050
18050
|
/**
|
|
18051
18051
|
* @param {ShapeLike} shape
|
|
18052
|
+
* @param {number} [borderRadius]
|
|
18052
18053
|
*
|
|
18053
18054
|
* @return {string} path
|
|
18054
18055
|
*/
|
|
@@ -21327,6 +21328,8 @@
|
|
|
21327
21328
|
* @typedef {import('../model/Types').Element} Element
|
|
21328
21329
|
* @typedef {import('../model/Types').Label} Label
|
|
21329
21330
|
* @typedef {import('../model/Types').Shape} Shape
|
|
21331
|
+
* @typedef {import('../model/Types').Connection} Connection
|
|
21332
|
+
* @typedef {import('../model/Types').Root} Root
|
|
21330
21333
|
* @typedef {import('../model/Types').ModdleElement} ModdleElement
|
|
21331
21334
|
*/
|
|
21332
21335
|
|
|
@@ -21407,6 +21410,8 @@
|
|
|
21407
21410
|
* @param {ModdleElement} semantic
|
|
21408
21411
|
* @param {ModdleElement} di
|
|
21409
21412
|
* @param {Shape} parentElement
|
|
21413
|
+
*
|
|
21414
|
+
* @return {Shape | Root | Connection}
|
|
21410
21415
|
*/
|
|
21411
21416
|
BpmnImporter.prototype.add = function(semantic, di, parentElement) {
|
|
21412
21417
|
var element,
|
|
@@ -38686,6 +38691,9 @@
|
|
|
38686
38691
|
|
|
38687
38692
|
/**
|
|
38688
38693
|
* @typedef {import('../../../model/Types').Element} Element
|
|
38694
|
+
* @typedef {import('diagram-js/lib/features/popup-menu/PopupMenu').PopupMenuTarget} PopupMenuTarget
|
|
38695
|
+
*
|
|
38696
|
+
* @typedef {(entry: PopupMenuTarget) => boolean} DifferentTypeValidator
|
|
38689
38697
|
*/
|
|
38690
38698
|
|
|
38691
38699
|
/**
|
|
@@ -38695,7 +38703,7 @@
|
|
|
38695
38703
|
*
|
|
38696
38704
|
* @param {Element} element
|
|
38697
38705
|
*
|
|
38698
|
-
* @return {
|
|
38706
|
+
* @return {DifferentTypeValidator}
|
|
38699
38707
|
*/
|
|
38700
38708
|
function isDifferentType(element) {
|
|
38701
38709
|
|
|
@@ -38727,14 +38735,20 @@
|
|
|
38727
38735
|
}
|
|
38728
38736
|
|
|
38729
38737
|
/**
|
|
38738
|
+
* @typedef { () => string } LabelGetter
|
|
38739
|
+
*
|
|
38730
38740
|
* @typedef { {
|
|
38731
|
-
* label: string;
|
|
38741
|
+
* label: string | LabelGetter;
|
|
38732
38742
|
* actionName: string;
|
|
38733
38743
|
* className: string;
|
|
38734
|
-
* target
|
|
38744
|
+
* target?: {
|
|
38735
38745
|
* type: string;
|
|
38736
38746
|
* isExpanded?: boolean;
|
|
38737
|
-
*
|
|
38747
|
+
* isInterrupting?: boolean;
|
|
38748
|
+
* triggeredByEvent?: boolean;
|
|
38749
|
+
* cancelActivity?: boolean;
|
|
38750
|
+
* eventDefinitionType?: string;
|
|
38751
|
+
* eventDefinitionAttrs?: Record<string, any>
|
|
38738
38752
|
* };
|
|
38739
38753
|
* } } ReplaceOption
|
|
38740
38754
|
*/
|
|
@@ -40205,7 +40219,7 @@
|
|
|
40205
40219
|
/**
|
|
40206
40220
|
* Get popup menu header entries for the ad-hoc property of the given BPMN element.
|
|
40207
40221
|
*
|
|
40208
|
-
* @param {PopupMenuTarget}
|
|
40222
|
+
* @param {PopupMenuTarget} element
|
|
40209
40223
|
*
|
|
40210
40224
|
* @return {PopupMenuHeaderEntries}
|
|
40211
40225
|
*/
|
|
@@ -51356,9 +51370,9 @@
|
|
|
51356
51370
|
* @param {Element[]} elements
|
|
51357
51371
|
* @param {Shape} target
|
|
51358
51372
|
* @param {Element} source
|
|
51359
|
-
* @param {Point} position
|
|
51373
|
+
* @param {Point} [position]
|
|
51360
51374
|
*
|
|
51361
|
-
* @return {boolean}
|
|
51375
|
+
* @return {boolean | 'attach'}
|
|
51362
51376
|
*/
|
|
51363
51377
|
function canAttach(elements, target, source, position) {
|
|
51364
51378
|
|
|
@@ -51425,6 +51439,7 @@
|
|
|
51425
51439
|
*
|
|
51426
51440
|
* @param {Element[]} elements
|
|
51427
51441
|
* @param {Shape} [target]
|
|
51442
|
+
* @param {Point} [position]
|
|
51428
51443
|
*
|
|
51429
51444
|
* @return {CanReplaceResult}
|
|
51430
51445
|
*/
|
|
@@ -54840,6 +54855,8 @@
|
|
|
54840
54855
|
*/
|
|
54841
54856
|
|
|
54842
54857
|
/**
|
|
54858
|
+
* A factory for BPMN elements.
|
|
54859
|
+
*
|
|
54843
54860
|
* @param {Moddle} moddle
|
|
54844
54861
|
*/
|
|
54845
54862
|
function BpmnFactory(moddle) {
|
|
@@ -54932,6 +54949,8 @@
|
|
|
54932
54949
|
};
|
|
54933
54950
|
|
|
54934
54951
|
/**
|
|
54952
|
+
* @param {ModdleElement} semantic
|
|
54953
|
+
* @param {Object} [attrs]
|
|
54935
54954
|
* @return {ModdleElement}
|
|
54936
54955
|
*/
|
|
54937
54956
|
BpmnFactory.prototype.createDiShape = function(semantic, attrs) {
|
|
@@ -54972,7 +54991,7 @@
|
|
|
54972
54991
|
|
|
54973
54992
|
/**
|
|
54974
54993
|
* @param {ModdleElement} semantic
|
|
54975
|
-
* @param {Object} attrs
|
|
54994
|
+
* @param {Object} [attrs]
|
|
54976
54995
|
*
|
|
54977
54996
|
* @return {ModdleElement}
|
|
54978
54997
|
*/
|
|
@@ -54985,7 +55004,7 @@
|
|
|
54985
55004
|
|
|
54986
55005
|
/**
|
|
54987
55006
|
* @param {ModdleElement} semantic
|
|
54988
|
-
* @param {Object} attrs
|
|
55007
|
+
* @param {Object} [attrs]
|
|
54989
55008
|
*
|
|
54990
55009
|
* @return {ModdleElement}
|
|
54991
55010
|
*/
|
|
@@ -55846,7 +55865,7 @@
|
|
|
55846
55865
|
* Create a root element.
|
|
55847
55866
|
*
|
|
55848
55867
|
* @overlord
|
|
55849
|
-
* @param {'root'}
|
|
55868
|
+
* @param {'root'} elementType
|
|
55850
55869
|
* @param {Partial<Root> & Partial<BpmnAttributes>} [attrs]
|
|
55851
55870
|
* @return {V}
|
|
55852
55871
|
*/
|
|
@@ -55855,7 +55874,7 @@
|
|
|
55855
55874
|
* Create a shape.
|
|
55856
55875
|
*
|
|
55857
55876
|
* @overlord
|
|
55858
|
-
* @param {'shape'}
|
|
55877
|
+
* @param {'shape'} elementType
|
|
55859
55878
|
* @param {Partial<Shape> & Partial<BpmnAttributes>} [attrs]
|
|
55860
55879
|
* @return {W}
|
|
55861
55880
|
*/
|
|
@@ -55864,7 +55883,7 @@
|
|
|
55864
55883
|
* Create a connection.
|
|
55865
55884
|
*
|
|
55866
55885
|
* @overlord
|
|
55867
|
-
* @param {'connection'}
|
|
55886
|
+
* @param {'connection'} elementType
|
|
55868
55887
|
* @param {Partial<Connection> & Partial<BpmnAttributes>} [attrs]
|
|
55869
55888
|
* @return {T}
|
|
55870
55889
|
*/
|
|
@@ -55872,7 +55891,7 @@
|
|
|
55872
55891
|
/**
|
|
55873
55892
|
* Create a label.
|
|
55874
55893
|
*
|
|
55875
|
-
* @param {'label'}
|
|
55894
|
+
* @param {'label'} elementType
|
|
55876
55895
|
* @param {Partial<Label> & Partial<BpmnAttributes>} [attrs]
|
|
55877
55896
|
* @return {U}
|
|
55878
55897
|
*/
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! bpmn-js - bpmn-modeler v13.0.
|
|
1
|
+
/*! bpmn-js - bpmn-modeler v13.0.2 | Copyright (c) 2014-present, camunda Services GmbH | bpmn.io/license */
|
|
2
2
|
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).BpmnJS=t()}(this,(function(){"use strict";function e(e,t){t&&(e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}var t=function(e,t){return e(t={exports:{}},t.exports),t.exports}((function(e){var t=e.exports=function(e,n){if(n||(n=16),void 0===e&&(e=128),e<=0)return"0";for(var i=Math.log(Math.pow(2,e))/Math.log(n),r=2;i===1/0;r*=2)i=Math.log(Math.pow(2,e/r))/Math.log(n)*r;var o=i-Math.floor(i),a="";for(r=0;r<Math.floor(i);r++){a=Math.floor(Math.random()*n).toString(n)+a}if(o){var s=Math.pow(n,o);a=Math.floor(Math.random()*s).toString(n)+a}var c=parseInt(a,n);return c!==1/0&&c>=Math.pow(2,e)?t(e,n):a};t.rack=function(e,n,i){var r=function(r){var a=0;do{if(a++>10){if(!i)throw new Error("too many ID collisions, use more bits");e+=i}var s=t(e,n)}while(Object.hasOwnProperty.call(o,s));return o[s]=r,s},o=r.hats={};return r.get=function(e){return r.hats[e]},r.set=function(e,t){return r.hats[e]=t,r},r.bits=e||128,r.base=n||16,r}}));function n(e){if(!(this instanceof n))return new n(e);e=e||[128,36,1],this._seed=e.length?t.rack(e[0],e[1],e[2]):e}function i(e){return Array.prototype.concat.apply([],e)}n.prototype.next=function(e){return this._seed(e||!0)},n.prototype.nextPrefixed=function(e,t){var n;do{n=e+this.next(!0)}while(this.assigned(n));return this.claim(n,t),n},n.prototype.claim=function(e,t){this._seed.set(e,t||!0)},n.prototype.assigned=function(e){return this._seed.get(e)||!1},n.prototype.unclaim=function(e){delete this._seed.hats[e]},n.prototype.clear=function(){var e,t=this._seed.hats;for(e in t)this.unclaim(e)};const r=Object.prototype.toString,o=Object.prototype.hasOwnProperty;function a(e){return void 0===e}function s(e){return void 0!==e}function c(e){return null==e}function p(e){return"[object Array]"===r.call(e)}function l(e){return"[object Object]"===r.call(e)}function u(e){return"[object Number]"===r.call(e)}function h(e){const t=r.call(e);return"[object Function]"===t||"[object AsyncFunction]"===t||"[object GeneratorFunction]"===t||"[object AsyncGeneratorFunction]"===t||"[object Proxy]"===t}function d(e){return"[object String]"===r.call(e)}function f(e,t){return o.call(e,t)}function m(e,t){const n=M(t);let i;return g(e,(function(e,t){if(n(e,t))return i=e,!1})),i}function v(e,t){const n=M(t);let i=p(e)?-1:void 0;return g(e,(function(e,t){if(n(e,t))return i=t,!1})),i}function y(e,t){const n=M(t);let i=[];return g(e,(function(e,t){n(e,t)&&i.push(e)})),i}function g(e,t){let n,i;if(a(e))return;const r=p(e)?N:B;for(let o in e)if(f(e,o)&&(n=e[o],i=t(n,r(o)),!1===i))return n}function b(e,t){if(a(e))return[];!function(e){if(!p(e))throw new Error("must supply array")}(e);const n=M(t);return e.filter((function(e,t){return!n(e,t)}))}function x(e,t,n){return g(e,(function(e,i){n=t(n,e,i)})),n}function _(e,t){return!!x(e,(function(e,n,i){return e&&t(n,i)}),!0)}function E(e,t){return!!m(e,t)}function w(e,t){let n=[];return g(e,(function(e,i){n.push(t(e,i))})),n}function S(e){return e&&Object.keys(e)||[]}function C(e){return w(e,(e=>e))}function A(e,t,n={}){return t=D(t),g(e,(function(e){let i=t(e)||"_",r=n[i];r||(r=n[i]=[]),r.push(e)})),n}function R(e,...t){e=D(e);let n={};return g(t,(t=>A(t,e,n))),w(n,(function(e,t){return e[0]}))}const T=R;function P(e,t){t=D(t);let n=[];return g(e,(function(e,i){let r=t(e,i),o={d:r,v:e};for(var a=0;a<n.length;a++){let{d:e}=n[a];if(r<e)return void n.splice(a,0,o)}n.push(o)})),w(n,(e=>e.v))}function k(e){return function(t){return _(e,(function(e,n){return t[n]===e}))}}function D(e){return h(e)?e:t=>t[e]}function M(e){return h(e)?e:t=>t===e}function B(e){return e}function N(e){return Number(e)}function O(e,t){let n,i,r,o;function a(n){let a=Date.now(),p=n?0:o+t-a;if(p>0)return s(p);e.apply(r,i),c()}function s(e){n=setTimeout(a,e)}function c(){n&&clearTimeout(n),n=o=i=r=void 0}function p(...e){o=Date.now(),i=e,r=this,n||s(t)}return p.flush=function(){n&&a(!0),c()},p.cancel=c,p}function j(e,t){return e.bind(t)}function L(e,...t){return Object.assign(e,...t)}function I(e,t){let n={},i=Object(e);return g(t,(function(t){t in i&&(n[t]=e[t])})),n}function F(e,t){let n={};return g(Object(e),(function(e,i){-1===t.indexOf(i)&&(n[i]=e)})),n}function $(e,t){return t.forEach((function(t){t&&"string"!=typeof t&&!Array.isArray(t)&&Object.keys(t).forEach((function(n){if("default"!==n&&!(n in e)){var i=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(e,n,i.get?i:{enumerable:!0,get:function(){return t[n]}})}}))})),Object.freeze(e)}const z=Object.prototype.toString,H=Object.prototype.hasOwnProperty;function V(e,t){return H.call(e,t)}function G(e,t){let n,i;if(void 0===e)return;const r=function(e){return"[object Array]"===z.call(e)}(e)?U:W;for(let o in e)if(V(e,o)&&(n=e[o],i=t(n,r(o)),!1===i))return n}function W(e){return e}function U(e){return Number(e)}function q(e,...t){const n=e.style;return G(t,(function(e){e&&G(e,(function(e,t){n[t]=e}))})),e}function K(e,t,n){return 2==arguments.length?e.getAttribute(t):null===n?e.removeAttribute(t):(e.setAttribute(t,n),e)}const Y=Object.prototype.toString;function X(e){return new Z(e)}function Z(e){if(!e||!e.nodeType)throw new Error("A DOM element reference is required");this.el=e,this.list=e.classList}function Q(e){for(var t;e.childNodes.length;)t=e.childNodes[0],e.removeChild(t);return e}function J(e,t){return e&&"function"==typeof e.matches&&e.matches(t)}function ee(e,t,n){for(var i=n?e:e.parentNode;i&&i.nodeType!==document.DOCUMENT_NODE&&i.nodeType!==document.DOCUMENT_FRAGMENT_NODE;){if(J(i,t))return i;i=i.parentNode}return J(i,t)?i:null}Z.prototype.add=function(e){return this.list.add(e),this},Z.prototype.remove=function(e){return"[object RegExp]"==Y.call(e)?this.removeMatching(e):(this.list.remove(e),this)},Z.prototype.removeMatching=function(e){const t=this.array();for(let n=0;n<t.length;n++)e.test(t[n])&&this.remove(t[n]);return this},Z.prototype.toggle=function(e,t){return void 0!==t?t!==this.list.toggle(e,t)&&this.list.toggle(e):this.list.toggle(e),this},Z.prototype.array=function(){return Array.from(this.list)},Z.prototype.has=Z.prototype.contains=function(e){return this.list.contains(e)};var te,ne,ie,re={};function oe(){te=window.addEventListener?"addEventListener":"attachEvent",ne=window.removeEventListener?"removeEventListener":"detachEvent",ie="addEventListener"!==te?"on":""}var ae=$({__proto__:null,bind:re.bind=function(e,t,n,i){return te||oe(),e[te](ie+t,n,i||!1),n},unbind:re.unbind=function(e,t,n,i){return ne||oe(),e[ne](ie+t,n,i||!1),n},default:re},[re]),se=["focus","blur"];var ce,pe={bind:function(e,t,n,i,r){return-1!==se.indexOf(n)&&(r=!0),ae.bind(e,n,(function(n){var r=n.target||n.srcElement;n.delegateTarget=ee(r,t,!0),n.delegateTarget&&i.call(e,n)}),r)},unbind:function(e,t,n,i){return-1!==se.indexOf(t)&&(i=!0),ae.unbind(e,t,n,i)}},le=function(e,t){if("string"!=typeof e)throw new TypeError("String expected");t||(t=document);var n=/<([\w:]+)/.exec(e);if(!n)return t.createTextNode(e);e=e.replace(/^\s+|\s+$/g,"");var i=n[1];if("body"==i){return(r=t.createElement("html")).innerHTML=e,r.removeChild(r.lastChild)}var r,o=Object.prototype.hasOwnProperty.call(he,i)?he[i]:he._default,a=o[0],s=o[1],c=o[2];(r=t.createElement("div")).innerHTML=s+e+c;for(;a--;)r=r.lastChild;if(r.firstChild==r.lastChild)return r.removeChild(r.firstChild);var p=t.createDocumentFragment();for(;r.firstChild;)p.appendChild(r.removeChild(r.firstChild));return p},ue=!1;"undefined"!=typeof document&&((ce=document.createElement("div")).innerHTML=' <link/><table></table><a href="/a">a</a><input type="checkbox"/>',ue=!ce.getElementsByTagName("link").length,ce=void 0);var he={legend:[1,"<fieldset>","</fieldset>"],tr:[2,"<table><tbody>","</tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],_default:ue?[1,"X<div>","</div>"]:[0,"",""]};he.td=he.th=[3,"<table><tbody><tr>","</tr></tbody></table>"],he.option=he.optgroup=[1,'<select multiple="multiple">',"</select>"],he.thead=he.tbody=he.colgroup=he.caption=he.tfoot=[1,"<table>","</table>"],he.polyline=he.ellipse=he.polygon=he.circle=he.text=he.line=he.path=he.rect=he.g=[1,'<svg xmlns="http://www.w3.org/2000/svg" version="1.1">',"</svg>"];var de=le;function fe(e,t){return(t=t||document).querySelector(e)}function me(e,t){return(t=t||document).querySelectorAll(e)}function ve(e){e.parentNode&&e.parentNode.removeChild(e)}function ye(e,t){return t.appendChild(function(e,t){if(e.ownerDocument!==t.ownerDocument)try{return t.ownerDocument.importNode(e,!0)}catch(e){}return e}(e,t))}function ge(e,t){return ye(t,e),e}var be={"alignment-baseline":1,"baseline-shift":1,clip:1,"clip-path":1,"clip-rule":1,color:1,"color-interpolation":1,"color-interpolation-filters":1,"color-profile":1,"color-rendering":1,cursor:1,direction:1,display:1,"dominant-baseline":1,"enable-background":1,fill:1,"fill-opacity":1,"fill-rule":1,filter:1,"flood-color":1,"flood-opacity":1,font:1,"font-family":1,"font-size":2,"font-size-adjust":1,"font-stretch":1,"font-style":1,"font-variant":1,"font-weight":1,"glyph-orientation-horizontal":1,"glyph-orientation-vertical":1,"image-rendering":1,kerning:1,"letter-spacing":1,"lighting-color":1,marker:1,"marker-end":1,"marker-mid":1,"marker-start":1,mask:1,opacity:1,overflow:1,"pointer-events":1,"shape-rendering":1,"stop-color":1,"stop-opacity":1,stroke:1,"stroke-dasharray":1,"stroke-dashoffset":1,"stroke-linecap":1,"stroke-linejoin":1,"stroke-miterlimit":1,"stroke-opacity":1,"stroke-width":2,"text-anchor":1,"text-decoration":1,"text-rendering":1,"unicode-bidi":1,visibility:1,"word-spacing":1,"writing-mode":1};function xe(e,t,n){var i=t.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),r=be[i];r?(2===r&&"number"==typeof n&&(n=String(n)+"px"),e.style[i]=n):e.setAttributeNS(null,t,n)}function _e(e,t,n){if("string"==typeof t){if(void 0===n)return function(e,t){return be[t]?e.style[t]:e.getAttributeNS(null,t)}(e,t);xe(e,t,n)}else!function(e,t){var n,i,r=Object.keys(t);for(n=0;i=r[n];n++)xe(e,i,t[i])}(e,t);return e}const Ee=Object.prototype.toString;function we(e){return new Se(e)}function Se(e){if(!e||!e.nodeType)throw new Error("A DOM element reference is required");this.el=e,this.list=e.classList}function Ce(e){var t=e.parentNode;return t&&t.removeChild(e),e}function Ae(e){for(var t;t=e.firstChild;)Ce(t);return e}function Re(e){return e.cloneNode(!0)}Se.prototype.add=function(e){return this.list.add(e),this},Se.prototype.remove=function(e){return"[object RegExp]"==Ee.call(e)?this.removeMatching(e):(this.list.remove(e),this)},Se.prototype.removeMatching=function(e){const t=this.array();for(let n=0;n<t.length;n++)e.test(t[n])&&this.remove(t[n]);return this},Se.prototype.toggle=function(e,t){return void 0!==t?t!==this.list.toggle(e,t)&&this.list.toggle(e):this.list.toggle(e),this},Se.prototype.array=function(){return Array.from(this.list)},Se.prototype.has=Se.prototype.contains=function(e){return this.list.contains(e)};var Te="http://www.w3.org/2000/svg",Pe='<svg xmlns="'+Te+'"';function ke(e){var t=!1;"<svg"===e.substring(0,4)?-1===e.indexOf(Te)&&(e=Pe+e.substring(4)):(e=Pe+">"+e+"</svg>",t=!0);var n=function(e){var t;return(t=new DOMParser).async=!1,t.parseFromString(e,"text/xml")}(e);if(!t)return n;for(var i=document.createDocumentFragment(),r=n.firstChild;r.firstChild;)i.appendChild(r.firstChild);return i}function De(e,t){var n;return"<"===e.charAt(0)?(n=ke(e).firstChild,n=document.importNode(n,!0)):n=document.createElementNS(Te,e),t&&_e(n,t),n}var Me=null;function Be(){return null===Me&&(Me=De("svg")),Me}function Ne(e,t){var n,i,r=Object.keys(t);for(n=0;i=r[n];n++)e[i]=t[i];return e}function Oe(e){return e?Be().createSVGTransformFromMatrix(e):Be().createSVGTransform()}var je=/([&<>]{1})/g,Le=/([\n\r"]{1})/g,Ie={"&":"&","<":"<",">":">",'"':"'"};function Fe(e,t){return e.replace(t,(function(e,t){return Ie[t]||t}))}function $e(e,t){var n,i,r,o,a;switch(e.nodeType){case 3:t.push(Fe(e.textContent,je));break;case 1:if(t.push("<",e.tagName),e.hasAttributes())for(n=0,i=(r=e.attributes).length;n<i;++n)o=r.item(n),t.push(" ",o.name,'="',Fe(o.value,Le),'"');if(e.hasChildNodes()){for(t.push(">"),n=0,i=(a=e.childNodes).length;n<i;++n)$e(a.item(n),t);t.push("</",e.tagName,">")}else t.push("/>");break;case 8:t.push("\x3c!--",Fe(e.nodeValue,je),"--\x3e");break;case 4:t.push("<![CDATA[",e.nodeValue,"]]>");break;default:throw new Error("unable to handle node "+e.nodeType)}return t}function ze(e,t){var n=ke(t);if(Ae(e),t){(function(e){return"#document-fragment"===e.nodeName})(n)||(n=n.documentElement);for(var i,r=(i=n.childNodes,Array.prototype.slice.call(i)),o=0;o<r.length;o++)ye(r[o],e)}}function He(e,t){if(void 0!==t){try{ze(e,t)}catch(e){throw new Error("error parsing SVG: "+e.message)}return e}return function(e){for(var t=e.firstChild,n=[];t;)$e(t,n),t=t.nextSibling;return n.join("")}(e)}function Ve(e,t){return t instanceof SVGMatrix?e.createSVGTransformFromMatrix(t):t}function Ge(e,t){var n=e.transform.baseVal;return t&&(Array.isArray(t)||(t=[t]),function(e,t){var n,i;for(e.clear(),n=0;i=t[n];n++)e.appendItem(Ve(e,i))}(n,t)),n.consolidate()}const We=/^class[ {]/;function Ue(e){return Array.isArray(e)}function qe(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function Ke(...e){1===e.length&&Ue(e[0])&&(e=e[0]);const t=(e=[...e]).pop();return t.$inject=e,t}const Ye=/constructor\s*[^(]*\(\s*([^)]*)\)/m,Xe=/^(?:async\s+)?(?:function\s*[^(]*)?(?:\(\s*([^)]*)\)|(\w+))/m,Ze=/\/\*([^*]*)\*\//m;function Qe(e){if("function"!=typeof e)throw new Error(`Cannot annotate "${e}". Expected a function!`);const t=e.toString().match(function(e){return We.test(e.toString())}(e)?Ye:Xe);if(!t)return[];const n=t[1]||t[2];return n&&n.split(",").map((e=>{const t=e.match(Ze);return(t&&t[1]||e).trim()}))||[]}function Je(e,t){t=t||{get:function(e,t){if(n.push(e),!1===t)return null;throw a(`No provider for "${e}"!`)}};const n=[],i=this._providers=Object.create(t._providers||null),r=this._instances=Object.create(null),o=r.injector=this,a=function(e){const t=n.join(" -> ");return n.length=0,new Error(t?`${e} (Resolving: ${t})`:e)};function s(e,o){if(!i[e]&&-1!==e.indexOf(".")){const t=e.split(".");let n=s(t.shift());for(;t.length;)n=n[t.shift()];return n}if(qe(r,e))return r[e];if(qe(i,e)){if(-1!==n.indexOf(e))throw n.push(e),a("Cannot resolve circular dependency!");return n.push(e),r[e]=i[e][0](i[e][1]),n.pop(),r[e]}return t.get(e,o)}function c(e,t){if(void 0===t&&(t={}),"function"!=typeof e){if(!Ue(e))throw a(`Cannot invoke "${e}". Expected a function!`);e=Ke(e.slice())}return{fn:e,dependencies:(e.$inject||Qe(e)).map((e=>qe(t,e)?t[e]:s(e)))}}function p(e){const{fn:t,dependencies:n}=c(e);return new(Function.prototype.bind.apply(t,[null].concat(n)))}function l(e,t,n){const{fn:i,dependencies:r}=c(e,n);return i.apply(t,r)}function u(e){return Ke((t=>e.get(t)))}function h(e,t){if(t&&t.length){const n=Object.create(null),r=Object.create(null),o=[],a=[],s=[];let c,p,l,h;for(let e in i)c=i[e],-1!==t.indexOf(e)&&("private"===c[2]?(p=o.indexOf(c[3]),-1===p?(l=c[3].createChild([],t),h=u(l),o.push(c[3]),a.push(l),s.push(h),n[e]=[h,e,"private",l]):n[e]=[s[p],e,"private",a[p]]):n[e]=[c[2],c[1]],r[e]=!0),"factory"!==c[2]&&"type"!==c[2]||!c[1].$scope||t.forEach((t=>{-1!==c[1].$scope.indexOf(t)&&(n[e]=[c[2],c[1]],r[t]=!0)}));t.forEach((e=>{if(!r[e])throw new Error('No provider for "'+e+'". Cannot use provider from the parent!')})),e.unshift(n)}return new Je(e,o)}const d={factory:l,type:p,value:function(e){return e}};function f(e,t){const n=e.__init__||[];return function(){n.forEach((e=>{"string"==typeof e?t.get(e):t.invoke(e)}))}}function m(e){const t=e.__exports__;if(t){const n=e.__modules__,r=Object.keys(e).reduce(((t,n)=>("__exports__"!==n&&"__modules__"!==n&&"__init__"!==n&&"__depends__"!==n&&(t[n]=e[n]),t)),Object.create(null)),o=h((n||[]).concat(r)),a=Ke((function(e){return o.get(e)}));t.forEach((function(e){i[e]=[a,e,"private",o]}));const s=(e.__init__||[]).slice();return s.unshift((function(){o.init()})),f(e=Object.assign({},e,{__init__:s}),o)}return Object.keys(e).forEach((function(t){if("__init__"===t||"__depends__"===t)return;if("private"===e[t][2])return void(i[t]=e[t]);const n=e[t][0],r=e[t][1];i[t]=[d[n],et(n,r),n]})),f(e,o)}function v(e,t){return-1!==e.indexOf(t)||-1!==(e=(t.__depends__||[]).reduce(v,e)).indexOf(t)?e:e.concat(t)}this.get=s,this.invoke=l,this.instantiate=p,this.createChild=h,this.init=function(e){const t=e.reduce(v,[]).map(m);let n=!1;return function(){n||(n=!0,t.forEach((e=>e())))}}(e)}function et(e,t){return"value"!==e&&Ue(t)&&(t=Ke(t.slice())),t}function tt(e,t){var n=this;t=t||1e3,e.on(["render.shape","render.connection"],t,(function(e,t){var i=e.type,r=t.element,o=t.gfx,a=t.attrs;if(n.canRender(r))return"render.shape"===i?n.drawShape(o,r,a):n.drawConnection(o,r,a)})),e.on(["render.getShapePath","render.getConnectionPath"],t,(function(e,t){if(n.canRender(t))return"render.getShapePath"===e.type?n.getShapePath(t):n.getConnectionPath(t)}))}function nt(e){return e.flat().join(",").replace(/,?([A-z]),?/g,"$1")}function it(e){return["L",e.x,e.y]}function rt(e,t){const n=e.length,i=[(r=e[0],["M",r.x,r.y])];var r,o,a,s;for(let r=1;r<n;r++){const n=e[r-1],c=e[r],p=e[r+1];if(!p||!t){i.push(it(c));continue}const l=Math.min(t,at(c.x-n.x,c.y-n.y),at(p.x-c.x,p.y-c.y));if(!l){i.push(it(c));continue}const u=ot(c,n,l),h=ot(c,n,.5*l),d=ot(c,p,l),f=ot(c,p,.5*l);i.push(it(u)),i.push((a=f,s=d,["C",(o=h).x,o.y,a.x,a.y,s.x,s.y]))}return i}function ot(e,t,n){const i=t.x-e.x,r=t.y-e.y,o=n/at(i,r);return{x:e.x+i*o,y:e.y+r*o}}function at(e,t){return Math.sqrt(Math.pow(e,2)+Math.pow(t,2))}function st(e,t,n){u(t)&&(n=t,t=null),t||(t={});const i=De("path",t);return u(n)&&(i.dataset.cornerRadius=String(n)),ct(i,e)}function ct(e,t){return _e(e,{d:nt(rt(t,parseInt(e.dataset.cornerRadius,10)||0))}),e}function pt(e){return y(e,(function(t){return!m(e,(function(e){return e!==t&<(t,e)}))}))}function lt(e,t){if(t){if(e===t)return t;if(e.parent)return lt(e.parent,t)}}function ut(e,t,n){var i=!n||-1===e.indexOf(t);return i&&e.push(t),i}function ht(e,t,n){n=n||0,p(e)||(e=[e]),g(e,(function(e,i){var r=t(e,i,n);p(r)&&r.length&&ht(r,t,n+1)}))}function dt(e,t){return function(e,t,n){var i=[],r=[];return ht(e,(function(e,o,a){ut(i,e,t);var s=e.children;if((-1===n||a<n)&&s&&ut(r,s,t))return s})),i}(e,!t,-1)}function ft(e,t){var n,i,r,o;return t=!!t,p(e)||(e=[e]),g(e,(function(e){var a=e;e.waypoints&&!t&&(a=ft(e.waypoints,!0));var s=a.x,c=a.y,p=a.height||0,l=a.width||0;(s<n||void 0===n)&&(n=s),(c<i||void 0===i)&&(i=c),(s+l>r||void 0===r)&&(r=s+l),(c+p>o||void 0===o)&&(o=c+p)})),{x:n,y:i,height:o-i,width:r-n}}function mt(e){return"waypoints"in e?"connection":"x"in e?"shape":"root"}function vt(e){return!(!e||!e.isFrame)}function yt(e,t){return L({},e||{},t||{})}tt.prototype.canRender=function(e){},tt.prototype.drawShape=function(e,t){},tt.prototype.drawConnection=function(e,t){},tt.prototype.getShapePath=function(e){},tt.prototype.getConnectionPath=function(e){};function gt(e,t){tt.call(this,e,1),this.CONNECTION_STYLE=t.style(["no-fill"],{strokeWidth:5,stroke:"fuchsia"}),this.SHAPE_STYLE=t.style({fill:"white",stroke:"fuchsia",strokeWidth:2}),this.FRAME_STYLE=t.style(["no-fill"],{stroke:"fuchsia",strokeDasharray:4,strokeWidth:2})}e(gt,tt),gt.prototype.canRender=function(){return!0},gt.prototype.drawShape=function(e,t,n){var i=De("rect");return _e(i,{x:0,y:0,width:t.width||0,height:t.height||0}),vt(t)?_e(i,L({},this.FRAME_STYLE,n||{})):_e(i,L({},this.SHAPE_STYLE,n||{})),ge(e,i),i},gt.prototype.drawConnection=function(e,t,n){var i=st(t.waypoints,L({},this.CONNECTION_STYLE,n||{}));return ge(e,i),i},gt.prototype.getShapePath=function(e){var t=e.x,n=e.y,i=e.width;return nt([["M",t,n],["l",i,0],["l",0,e.height],["l",-i,0],["z"]])},gt.prototype.getConnectionPath=function(e){var t,n,i=e.waypoints,r=[];for(t=0;n=i[t];t++)n=n.original||n,r.push([0===t?"M":"L",n.x,n.y]);return nt(r)},gt.$inject=["eventBus","styles"];var bt={__init__:["defaultRenderer"],defaultRenderer:["type",gt],styles:["type",function(){var e={"no-fill":{fill:"none"},"no-border":{strokeOpacity:0},"no-events":{pointerEvents:"none"}},t=this;this.cls=function(e,t,n){return L(this.style(t,n),{class:e})},this.style=function(t,n){p(t)||n||(n=t,t=[]);var i=x(t,(function(t,n){return L(t,e[n]||{})}),{});return n?L(i,n):i},this.computeStyle=function(e,n,i){return p(n)||(i=n,n=[]),t.style(n||[],L({},i,e||{}))}}]};function xt(e,t){if(!e||!t)return-1;var n=e.indexOf(t);return-1!==n&&e.splice(n,1),n}function _t(e,t,n){if(e&&t){"number"!=typeof n&&(n=-1);var i=e.indexOf(t);if(-1!==i){if(i===n)return;if(-1===n)return;e.splice(i,1)}-1!==n?e.splice(n,0,t):e.push(t)}}function Et(e,t){return e&&t?e.indexOf(t):-1}function wt(e,t){return e&&t?Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2)):-1}function St(e,t,n,i){if(void 0===i&&(i=5),!e||!t||!n)return!1;var r=(t.x-e.x)*(n.y-e.y)-(t.y-e.y)*(n.x-e.x),o=wt(e,t);return Math.abs(r/o)<=i}function Ct(e,t){var n=Array.from(arguments).flat();const i={x:"v",y:"h"};for(const[e,t]of Object.entries(i))if(At(e,n))return t;return!1}function At(e,t){const n=t[0];return _(t,(function(t){return Math.abs(n[e]-t[e])<=2}))}function Rt(e,t,n){return n=n||0,e.x>t.x-n&&e.y>t.y-n&&e.x<t.x+t.width+n&&e.y<t.y+t.height+n}function Tt(e,t){return{x:Math.round(e.x+(t.x-e.x)/2),y:Math.round(e.y+(t.y-e.y)/2)}}function Pt(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}
|
|
3
3
|
/**
|
|
4
4
|
* This file contains source code adapted from Snap.svg (licensed Apache-2.0).
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* bpmn-js - bpmn-navigated-viewer v13.0.
|
|
2
|
+
* bpmn-js - bpmn-navigated-viewer v13.0.2
|
|
3
3
|
*
|
|
4
4
|
* Copyright (c) 2014-present, camunda Services GmbH
|
|
5
5
|
*
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
*
|
|
9
9
|
* Source Code: https://github.com/bpmn-io/bpmn-js
|
|
10
10
|
*
|
|
11
|
-
* Date: 2023-04-
|
|
11
|
+
* Date: 2023-04-20
|
|
12
12
|
*/
|
|
13
13
|
(function (global, factory) {
|
|
14
14
|
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
|
|
@@ -698,7 +698,7 @@
|
|
|
698
698
|
|
|
699
699
|
/**
|
|
700
700
|
* @param {Element} element
|
|
701
|
-
* @param {ModdleElement} di
|
|
701
|
+
* @param {ModdleElement} [di]
|
|
702
702
|
*
|
|
703
703
|
* @return {boolean}
|
|
704
704
|
*/
|
|
@@ -1665,7 +1665,7 @@
|
|
|
1665
1665
|
|
|
1666
1666
|
/**
|
|
1667
1667
|
* @param {DiagramElement} element
|
|
1668
|
-
* @param {string} defaultColor
|
|
1668
|
+
* @param {string} [defaultColor]
|
|
1669
1669
|
*
|
|
1670
1670
|
* @return {string}
|
|
1671
1671
|
*/
|
|
@@ -1677,7 +1677,7 @@
|
|
|
1677
1677
|
|
|
1678
1678
|
/**
|
|
1679
1679
|
* @param {DiagramElement} element
|
|
1680
|
-
* @param {string} defaultColor
|
|
1680
|
+
* @param {string} [defaultColor]
|
|
1681
1681
|
*
|
|
1682
1682
|
* @return {string}
|
|
1683
1683
|
*/
|
|
@@ -1728,6 +1728,7 @@
|
|
|
1728
1728
|
|
|
1729
1729
|
/**
|
|
1730
1730
|
* @param {ShapeLike} shape
|
|
1731
|
+
* @param {number} [borderRadius]
|
|
1731
1732
|
*
|
|
1732
1733
|
* @return {string} path
|
|
1733
1734
|
*/
|
|
@@ -5911,6 +5912,8 @@
|
|
|
5911
5912
|
* @typedef {import('../model/Types').Element} Element
|
|
5912
5913
|
* @typedef {import('../model/Types').Label} Label
|
|
5913
5914
|
* @typedef {import('../model/Types').Shape} Shape
|
|
5915
|
+
* @typedef {import('../model/Types').Connection} Connection
|
|
5916
|
+
* @typedef {import('../model/Types').Root} Root
|
|
5914
5917
|
* @typedef {import('../model/Types').ModdleElement} ModdleElement
|
|
5915
5918
|
*/
|
|
5916
5919
|
|
|
@@ -5991,6 +5994,8 @@
|
|
|
5991
5994
|
* @param {ModdleElement} semantic
|
|
5992
5995
|
* @param {ModdleElement} di
|
|
5993
5996
|
* @param {Shape} parentElement
|
|
5997
|
+
*
|
|
5998
|
+
* @return {Shape | Root | Connection}
|
|
5994
5999
|
*/
|
|
5995
6000
|
BpmnImporter.prototype.add = function(semantic, di, parentElement) {
|
|
5996
6001
|
var element,
|
|
@@ -21204,7 +21209,7 @@
|
|
|
21204
21209
|
* Find a suitable display candidate for definitions where the DI does not
|
|
21205
21210
|
* correctly specify one.
|
|
21206
21211
|
*
|
|
21207
|
-
* @param {ModdleElement}
|
|
21212
|
+
* @param {ModdleElement} definitions
|
|
21208
21213
|
*
|
|
21209
21214
|
* @return {ModdleElement}
|
|
21210
21215
|
*/
|
|
@@ -21215,7 +21220,7 @@
|
|
|
21215
21220
|
}
|
|
21216
21221
|
|
|
21217
21222
|
/**
|
|
21218
|
-
* @param {Function} handler
|
|
21223
|
+
* @param {Record<'element' | 'root' | 'error', Function>} handler
|
|
21219
21224
|
* @param {Translate} translate
|
|
21220
21225
|
*/
|
|
21221
21226
|
function BpmnTreeWalker(handler, translate) {
|