verben-workflow-ui 0.5.93 → 0.5.94
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/esm2022/public-api.mjs +41 -0
- package/esm2022/src/lib/base/core/base-data-page.facade.mjs +412 -0
- package/esm2022/src/lib/base/core/base-data-page.service.mjs +140 -0
- package/esm2022/src/lib/base/core/base-data-page.state.mjs +216 -0
- package/esm2022/src/lib/base/handlers/filter-handler.service.mjs +138 -0
- package/esm2022/src/lib/base/handlers/search-handler.service.mjs +31 -0
- package/esm2022/src/lib/base/handlers/sort-handler.service.mjs +73 -0
- package/esm2022/src/lib/base/index.mjs +2 -0
- package/esm2022/src/lib/base/models/api-payload.mjs +7 -0
- package/esm2022/src/lib/base/models/page-config.interface.mjs +2 -0
- package/esm2022/src/lib/base/models/page-filter-tab-option.interface.mjs +2 -0
- package/esm2022/src/lib/base/public-api.mjs +14 -0
- package/esm2022/src/lib/base/utils/column-helpers.mjs +55 -0
- package/esm2022/src/lib/base/verben-workflow-ui-src-lib-base.mjs +5 -0
- package/esm2022/src/lib/components/actors/actors.columns.mjs +39 -0
- package/esm2022/src/lib/components/actors/actors.component.mjs +175 -0
- package/esm2022/src/lib/components/actors/actors.config.mjs +49 -0
- package/esm2022/src/lib/components/actors/actors.facade.mjs +57 -0
- package/esm2022/src/lib/components/actors/actors.form.component.mjs +74 -0
- package/esm2022/src/lib/components/actors/actors.module.mjs +21 -0
- package/esm2022/src/lib/components/actors/actors.service.mjs +65 -0
- package/esm2022/src/lib/components/actors/actors.state.mjs +31 -0
- package/esm2022/src/lib/components/actors/index.mjs +2 -0
- package/esm2022/src/lib/components/actors/public-api.mjs +3 -0
- package/esm2022/src/lib/components/actors/verben-workflow-ui-src-lib-components-actors.mjs +5 -0
- package/esm2022/src/lib/components/designer/components/label-editor.component.mjs +148 -0
- package/esm2022/src/lib/components/designer/components/node-selector.component.mjs +317 -0
- package/esm2022/src/lib/components/designer/components/swimlane-label.component.mjs +161 -0
- package/esm2022/src/lib/components/designer/components/swimlane-popup.component.mjs +85 -0
- package/esm2022/src/lib/components/designer/components/wf-canvas.component.mjs +715 -0
- package/esm2022/src/lib/components/designer/components/wf-designer.component.mjs +135 -0
- package/esm2022/src/lib/components/designer/components/wf-toolbar.component.mjs +56 -0
- package/esm2022/src/lib/components/designer/index.mjs +2 -0
- package/esm2022/src/lib/components/designer/models/types.mjs +2 -0
- package/esm2022/src/lib/components/designer/public-api.mjs +3 -0
- package/esm2022/src/lib/components/designer/services/canvas-state.service.mjs +50 -0
- package/esm2022/src/lib/components/designer/services/connection-segment-interaction.service.mjs +108 -0
- package/esm2022/src/lib/components/designer/services/connection.service.mjs +266 -0
- package/esm2022/src/lib/components/designer/services/keyboard-handler.service.mjs +43 -0
- package/esm2022/src/lib/components/designer/services/label-management.service.mjs +66 -0
- package/esm2022/src/lib/components/designer/services/node-finder.service.mjs +30 -0
- package/esm2022/src/lib/components/designer/services/node-interaction.service.mjs +108 -0
- package/esm2022/src/lib/components/designer/services/node-precondition.service.mjs +108 -0
- package/esm2022/src/lib/components/designer/services/node-selection.service.mjs +96 -0
- package/esm2022/src/lib/components/designer/services/orthogonal-router.service.mjs +167 -0
- package/esm2022/src/lib/components/designer/services/position-update.service.mjs +45 -0
- package/esm2022/src/lib/components/designer/services/rendering.service.mjs +236 -0
- package/esm2022/src/lib/components/designer/services/swimlane-management.service.mjs +145 -0
- package/esm2022/src/lib/components/designer/services/swimlane-stats.service.mjs +44 -0
- package/esm2022/src/lib/components/designer/services/viewport.service.mjs +30 -0
- package/esm2022/src/lib/components/designer/services/wf-facade.service.mjs +239 -0
- package/esm2022/src/lib/components/designer/services/wf-mapper.service.mjs +323 -0
- package/esm2022/src/lib/components/designer/services/wf-persistence.service.mjs +169 -0
- package/esm2022/src/lib/components/designer/services/wf-state.service.mjs +108 -0
- package/esm2022/src/lib/components/designer/verben-workflow-ui-src-lib-components-designer.mjs +5 -0
- package/esm2022/src/lib/components/expiration/expiration.component.mjs +49 -0
- package/esm2022/src/lib/components/expiration/expiration.module.mjs +19 -0
- package/esm2022/src/lib/components/expiration/index.mjs +2 -0
- package/esm2022/src/lib/components/expiration/public-api.mjs +3 -0
- package/esm2022/src/lib/components/expiration/verben-workflow-ui-src-lib-components-expiration.mjs +5 -0
- package/esm2022/src/lib/components/file-render/file-render.component.mjs +45 -0
- package/esm2022/src/lib/components/file-render/file-render.module.mjs +35 -0
- package/esm2022/src/lib/components/file-render/index.mjs +2 -0
- package/esm2022/src/lib/components/file-render/public-api.mjs +3 -0
- package/esm2022/src/lib/components/file-render/verben-workflow-ui-src-lib-components-file-render.mjs +5 -0
- package/esm2022/src/lib/components/file-upload/file-upload.component.mjs +93 -0
- package/esm2022/src/lib/components/file-upload/file-upload.module.mjs +63 -0
- package/esm2022/src/lib/components/file-upload/index.mjs +2 -0
- package/esm2022/src/lib/components/file-upload/public-api.mjs +3 -0
- package/esm2022/src/lib/components/file-upload/verben-workflow-ui-src-lib-components-file-upload.mjs +5 -0
- package/esm2022/src/lib/components/flowable-status/flowable-status.columns.mjs +21 -0
- package/esm2022/src/lib/components/flowable-status/flowable-status.component.mjs +203 -0
- package/esm2022/src/lib/components/flowable-status/flowable-status.config.mjs +47 -0
- package/esm2022/src/lib/components/flowable-status/flowable-status.facade.mjs +60 -0
- package/esm2022/src/lib/components/flowable-status/flowable-status.form.component.mjs +52 -0
- package/esm2022/src/lib/components/flowable-status/flowable-status.module.mjs +21 -0
- package/esm2022/src/lib/components/flowable-status/flowable-status.service.mjs +35 -0
- package/esm2022/src/lib/components/flowable-status/flowable-status.state.mjs +15 -0
- package/esm2022/src/lib/components/flowable-status/index.mjs +2 -0
- package/esm2022/src/lib/components/flowable-status/public-api.mjs +3 -0
- package/esm2022/src/lib/components/flowable-status/verben-workflow-ui-src-lib-components-flowable-status.mjs +5 -0
- package/esm2022/src/lib/components/form-control/form-control.component.mjs +155 -0
- package/esm2022/src/lib/components/form-control/form-control.module.mjs +75 -0
- package/esm2022/src/lib/components/form-control/index.mjs +2 -0
- package/esm2022/src/lib/components/form-control/public-api.mjs +3 -0
- package/esm2022/src/lib/components/form-control/verben-workflow-ui-src-lib-components-form-control.mjs +5 -0
- package/esm2022/src/lib/components/form-group/base-table-style.mjs +53 -0
- package/esm2022/src/lib/components/form-group/form-fields/form-fields.component.mjs +952 -0
- package/esm2022/src/lib/components/form-group/form-fields/form-fields.module.mjs +75 -0
- package/esm2022/src/lib/components/form-group/form-fields/form-fields.service.mjs +73 -0
- package/esm2022/src/lib/components/form-group/form-group.component.mjs +699 -0
- package/esm2022/src/lib/components/form-group/form-group.module.mjs +85 -0
- package/esm2022/src/lib/components/form-group/form-group.service.mjs +56 -0
- package/esm2022/src/lib/components/form-group/index.mjs +2 -0
- package/esm2022/src/lib/components/form-group/public-api.mjs +5 -0
- package/esm2022/src/lib/components/form-group/verben-workflow-ui-src-lib-components-form-group.mjs +5 -0
- package/esm2022/src/lib/components/form-response/form-response.component.mjs +641 -0
- package/esm2022/src/lib/components/form-response/form-response.module.mjs +76 -0
- package/esm2022/src/lib/components/form-response/form-response.service.mjs +54 -0
- package/esm2022/src/lib/components/form-response/index.mjs +2 -0
- package/esm2022/src/lib/components/form-response/public-api.mjs +3 -0
- package/esm2022/src/lib/components/form-response/verben-workflow-ui-src-lib-components-form-response.mjs +5 -0
- package/esm2022/src/lib/components/form-timer/form-timer.component.mjs +47 -0
- package/esm2022/src/lib/components/form-timer/form-timer.module.mjs +28 -0
- package/esm2022/src/lib/components/form-timer/index.mjs +2 -0
- package/esm2022/src/lib/components/form-timer/public-api.mjs +3 -0
- package/esm2022/src/lib/components/form-timer/verben-workflow-ui-src-lib-components-form-timer.mjs +5 -0
- package/esm2022/src/lib/components/form-viewer/form-viewer.component.mjs +38 -0
- package/esm2022/src/lib/components/form-viewer/form-viewer.module.mjs +78 -0
- package/esm2022/src/lib/components/form-viewer/index.mjs +2 -0
- package/esm2022/src/lib/components/form-viewer/public-api.mjs +3 -0
- package/esm2022/src/lib/components/form-viewer/verben-workflow-ui-src-lib-components-form-viewer.mjs +5 -0
- package/esm2022/src/lib/components/forms/base-table-style.mjs +53 -0
- package/esm2022/src/lib/components/forms/forms.component.mjs +673 -0
- package/esm2022/src/lib/components/forms/forms.module.mjs +18 -0
- package/esm2022/src/lib/components/forms/forms.service.mjs +68 -0
- package/esm2022/src/lib/components/forms/index.mjs +2 -0
- package/esm2022/src/lib/components/forms/public-api.mjs +3 -0
- package/esm2022/src/lib/components/forms/verben-workflow-ui-src-lib-components-forms.mjs +5 -0
- package/esm2022/src/lib/components/journal/index.mjs +2 -0
- package/esm2022/src/lib/components/journal/journal.component.mjs +11 -0
- package/esm2022/src/lib/components/journal/journal.module.mjs +18 -0
- package/esm2022/src/lib/components/journal/public-api.mjs +3 -0
- package/esm2022/src/lib/components/journal/verben-workflow-ui-src-lib-components-journal.mjs +5 -0
- package/esm2022/src/lib/components/my-queue/index.mjs +2 -0
- package/esm2022/src/lib/components/my-queue/my-queue.columns.mjs +34 -0
- package/esm2022/src/lib/components/my-queue/my-queue.component.mjs +342 -0
- package/esm2022/src/lib/components/my-queue/my-queue.facade.mjs +502 -0
- package/esm2022/src/lib/components/my-queue/my-queue.module.mjs +46 -0
- package/esm2022/src/lib/components/my-queue/my-queue.service.mjs +144 -0
- package/esm2022/src/lib/components/my-queue/my-queue.state.mjs +108 -0
- package/esm2022/src/lib/components/my-queue/public-api.mjs +4 -0
- package/esm2022/src/lib/components/my-queue/tasks.form.component.mjs +167 -0
- package/esm2022/src/lib/components/my-queue/verben-workflow-ui-src-lib-components-my-queue.mjs +5 -0
- package/esm2022/src/lib/components/operation-popup/index.mjs +2 -0
- package/esm2022/src/lib/components/operation-popup/operation-popup.component.mjs +382 -0
- package/esm2022/src/lib/components/operation-popup/operation-popup.facade.mjs +338 -0
- package/esm2022/src/lib/components/operation-popup/operation-popup.service.mjs +71 -0
- package/esm2022/src/lib/components/operation-popup/operation-popup.state.mjs +44 -0
- package/esm2022/src/lib/components/operation-popup/public-api.mjs +2 -0
- package/esm2022/src/lib/components/operation-popup/verben-workflow-ui-src-lib-components-operation-popup.mjs +5 -0
- package/esm2022/src/lib/components/stage-details/index.mjs +2 -0
- package/esm2022/src/lib/components/stage-details/public-api.mjs +3 -0
- package/esm2022/src/lib/components/stage-details/stage-details.component.mjs +49 -0
- package/esm2022/src/lib/components/stage-details/stage-details.module.mjs +19 -0
- package/esm2022/src/lib/components/stage-details/verben-workflow-ui-src-lib-components-stage-details.mjs +5 -0
- package/esm2022/src/lib/components/task-form/index.mjs +2 -0
- package/esm2022/src/lib/components/task-form/public-api.mjs +3 -0
- package/esm2022/src/lib/components/task-form/task-form.component.mjs +18 -0
- package/esm2022/src/lib/components/task-form/task-form.module.mjs +72 -0
- package/esm2022/src/lib/components/task-form/verben-workflow-ui-src-lib-components-task-form.mjs +5 -0
- package/esm2022/src/lib/components/task-history/index.mjs +2 -0
- package/esm2022/src/lib/components/task-history/public-api.mjs +3 -0
- package/esm2022/src/lib/components/task-history/task-history.component.mjs +217 -0
- package/esm2022/src/lib/components/task-history/task-history.module.mjs +20 -0
- package/esm2022/src/lib/components/task-history/task-history.service.mjs +32 -0
- package/esm2022/src/lib/components/task-history/verben-workflow-ui-src-lib-components-task-history.mjs +5 -0
- package/esm2022/src/lib/components/task-notification/base-table-style.mjs +53 -0
- package/esm2022/src/lib/components/task-notification/index.mjs +2 -0
- package/esm2022/src/lib/components/task-notification/public-api.mjs +3 -0
- package/esm2022/src/lib/components/task-notification/task-notification.component.mjs +670 -0
- package/esm2022/src/lib/components/task-notification/task-notification.module.mjs +18 -0
- package/esm2022/src/lib/components/task-notification/task-notification.service.mjs +256 -0
- package/esm2022/src/lib/components/task-notification/verben-workflow-ui-src-lib-components-task-notification.mjs +5 -0
- package/esm2022/src/lib/components/tasks/index.mjs +2 -0
- package/esm2022/src/lib/components/tasks/public-api.mjs +6 -0
- package/esm2022/src/lib/components/tasks/tasks.columns.mjs +48 -0
- package/esm2022/src/lib/components/tasks/tasks.component.mjs +193 -0
- package/esm2022/src/lib/components/tasks/tasks.facade.mjs +372 -0
- package/esm2022/src/lib/components/tasks/tasks.form.component.mjs +162 -0
- package/esm2022/src/lib/components/tasks/tasks.models.mjs +4 -0
- package/esm2022/src/lib/components/tasks/tasks.module.mjs +52 -0
- package/esm2022/src/lib/components/tasks/tasks.service.mjs +137 -0
- package/esm2022/src/lib/components/tasks/tasks.state.mjs +108 -0
- package/esm2022/src/lib/components/tasks/verben-workflow-ui-src-lib-components-tasks.mjs +5 -0
- package/esm2022/src/lib/components/wf/index.mjs +2 -0
- package/esm2022/src/lib/components/wf/public-api.mjs +4 -0
- package/esm2022/src/lib/components/wf/verben-workflow-ui-src-lib-components-wf.mjs +5 -0
- package/esm2022/src/lib/components/wf/wf.columns.mjs +34 -0
- package/esm2022/src/lib/components/wf/wf.component.mjs +68 -0
- package/esm2022/src/lib/components/wf/wf.module.mjs +22 -0
- package/esm2022/src/lib/components/wf/wf.service.mjs +82 -0
- package/esm2022/src/lib/components/workflow/column.mjs +38 -0
- package/esm2022/src/lib/components/workflow/helper.mjs +47 -0
- package/esm2022/src/lib/components/workflow/index.mjs +2 -0
- package/esm2022/src/lib/components/workflow/public-api.mjs +4 -0
- package/esm2022/src/lib/components/workflow/table-style.mjs +53 -0
- package/esm2022/src/lib/components/workflow/verben-workflow-ui-src-lib-components-workflow.mjs +5 -0
- package/esm2022/src/lib/components/workflow/workflow.component.mjs +210 -0
- package/esm2022/src/lib/components/workflow/workflow.module.mjs +19 -0
- package/esm2022/src/lib/components/workflow-designer/action-dialog/action-dialog.component.mjs +125 -0
- package/esm2022/src/lib/components/workflow-designer/actor-tags-dialog/actor-tags-dialog.component.mjs +78 -0
- package/esm2022/src/lib/components/workflow-designer/conditions-popup/conditions-popup.component.mjs +87 -0
- package/esm2022/src/lib/components/workflow-designer/decision-popup/decision-popup.component.mjs +84 -0
- package/esm2022/src/lib/components/workflow-designer/designer-canvas/designer-canvas.component.mjs +1265 -0
- package/esm2022/src/lib/components/workflow-designer/designer-toolbar/designer-toolbar.component.mjs +96 -0
- package/esm2022/src/lib/components/workflow-designer/designer-toolbar/designer-toolbar.types.mjs +2 -0
- package/esm2022/src/lib/components/workflow-designer/escalation-dialog/escalation-dialog.component.mjs +242 -0
- package/esm2022/src/lib/components/workflow-designer/index.mjs +2 -0
- package/esm2022/src/lib/components/workflow-designer/public-api.mjs +5 -0
- package/esm2022/src/lib/components/workflow-designer/services/connection.service.mjs +237 -0
- package/esm2022/src/lib/components/workflow-designer/services/node-management.service.mjs +321 -0
- package/esm2022/src/lib/components/workflow-designer/services/popup.service.mjs +240 -0
- package/esm2022/src/lib/components/workflow-designer/services/swimlane.service.mjs +158 -0
- package/esm2022/src/lib/components/workflow-designer/services/transformer.service.mjs +278 -0
- package/esm2022/src/lib/components/workflow-designer/stage-dialog/stage-dialog.component.mjs +177 -0
- package/esm2022/src/lib/components/workflow-designer/stage-node/stage-node.component.mjs +226 -0
- package/esm2022/src/lib/components/workflow-designer/swimlane-dialog/swimlane-dialog.component.mjs +138 -0
- package/esm2022/src/lib/components/workflow-designer/verben-workflow-ui-src-lib-components-workflow-designer.mjs +5 -0
- package/esm2022/src/lib/components/workflow-designer/workflow-data.service.mjs +210 -0
- package/esm2022/src/lib/components/workflow-designer/workflow-designer.component.mjs +460 -0
- package/esm2022/src/lib/components/workflow-designer/workflow-designer.module.mjs +126 -0
- package/esm2022/src/lib/components/workflow-designer/workflow-designer.state.mjs +922 -0
- package/esm2022/src/lib/components/workflow-designer/workflow-designer.types.mjs +2 -0
- package/esm2022/src/lib/components/workflow-stage/index.mjs +2 -0
- package/esm2022/src/lib/components/workflow-stage/public-api.mjs +3 -0
- package/esm2022/src/lib/components/workflow-stage/verben-workflow-ui-src-lib-components-workflow-stage.mjs +5 -0
- package/esm2022/src/lib/components/workflow-stage/workflow-stage.component.mjs +328 -0
- package/esm2022/src/lib/components/workflow-stage/workflow-stage.module.mjs +82 -0
- package/esm2022/src/lib/components/workflows/index.mjs +2 -0
- package/esm2022/src/lib/components/workflows/public-api.mjs +7 -0
- package/esm2022/src/lib/components/workflows/verben-workflow-ui-src-lib-components-workflows.mjs +5 -0
- package/esm2022/src/lib/components/workflows/workflow-form/workflow-form.component.mjs +89 -0
- package/esm2022/src/lib/components/workflows/workflows.api.mjs +63 -0
- package/esm2022/src/lib/components/workflows/workflows.columns.mjs +39 -0
- package/esm2022/src/lib/components/workflows/workflows.component.mjs +236 -0
- package/esm2022/src/lib/components/workflows/workflows.config.mjs +51 -0
- package/esm2022/src/lib/components/workflows/workflows.facade.mjs +114 -0
- package/esm2022/src/lib/components/workflows/workflows.module.mjs +21 -0
- package/esm2022/src/lib/components/workflows/workflows.service.mjs +63 -0
- package/esm2022/src/lib/components/workflows/workflows.state.mjs +23 -0
- package/esm2022/src/lib/models/ActionHistory.mjs +2 -0
- package/esm2022/src/lib/models/ActionType.mjs +11 -0
- package/esm2022/src/lib/models/Actor.mjs +2 -0
- package/esm2022/src/lib/models/ActorTag.mjs +2 -0
- package/esm2022/src/lib/models/Coord.mjs +2 -0
- package/esm2022/src/lib/models/DataType.mjs +27 -0
- package/esm2022/src/lib/models/EAVEntity.mjs +2 -0
- package/esm2022/src/lib/models/ErrorResponse.mjs +11 -0
- package/esm2022/src/lib/models/Escalation.mjs +2 -0
- package/esm2022/src/lib/models/EscalationCycle.mjs +2 -0
- package/esm2022/src/lib/models/EscalationStage.mjs +2 -0
- package/esm2022/src/lib/models/EscalationType.mjs +7 -0
- package/esm2022/src/lib/models/File.mjs +2 -0
- package/esm2022/src/lib/models/FilterTypes.mjs +9 -0
- package/esm2022/src/lib/models/FlowableStatus.mjs +2 -0
- package/esm2022/src/lib/models/Form.mjs +2 -0
- package/esm2022/src/lib/models/FormEntity.mjs +2 -0
- package/esm2022/src/lib/models/FormFill.mjs +6 -0
- package/esm2022/src/lib/models/FormProperty.mjs +2 -0
- package/esm2022/src/lib/models/FormValues.mjs +2 -0
- package/esm2022/src/lib/models/MailConfig.mjs +2 -0
- package/esm2022/src/lib/models/MessageConfig.mjs +2 -0
- package/esm2022/src/lib/models/MessageMedium.mjs +6 -0
- package/esm2022/src/lib/models/OperationAction.mjs +2 -0
- package/esm2022/src/lib/models/PagedResult.mjs +2 -0
- package/esm2022/src/lib/models/PeriodMode.mjs +12 -0
- package/esm2022/src/lib/models/PermissionConfig.mjs +2 -0
- package/esm2022/src/lib/models/ReportSchedule.mjs +2 -0
- package/esm2022/src/lib/models/ReportType.mjs +7 -0
- package/esm2022/src/lib/models/Resource.mjs +47 -0
- package/esm2022/src/lib/models/ResponseKeyValue.mjs +2 -0
- package/esm2022/src/lib/models/SMSConfig.mjs +2 -0
- package/esm2022/src/lib/models/SearchDynamicWrapper.mjs +2 -0
- package/esm2022/src/lib/models/SearchOperator.mjs +6 -0
- package/esm2022/src/lib/models/SearchPropertySign.mjs +11 -0
- package/esm2022/src/lib/models/SearchPropertyValue.mjs +2 -0
- package/esm2022/src/lib/models/SearchPropertyValueType.mjs +11 -0
- package/esm2022/src/lib/models/Size.mjs +2 -0
- package/esm2022/src/lib/models/SortDirection.mjs +7 -0
- package/esm2022/src/lib/models/StageActorRule.mjs +8 -0
- package/esm2022/src/lib/models/SwimLane.mjs +2 -0
- package/esm2022/src/lib/models/Tag.mjs +2 -0
- package/esm2022/src/lib/models/Task.mjs +2 -0
- package/esm2022/src/lib/models/TaskAssignmentType.mjs +6 -0
- package/esm2022/src/lib/models/TaskNotification.mjs +2 -0
- package/esm2022/src/lib/models/TaskNotificationMessageType.mjs +6 -0
- package/esm2022/src/lib/models/TaskNotificationType.mjs +8 -0
- package/esm2022/src/lib/models/TaskStatus.mjs +9 -0
- package/esm2022/src/lib/models/Workflow.mjs +2 -0
- package/esm2022/src/lib/models/WorkflowAction.mjs +2 -0
- package/esm2022/src/lib/models/WorkflowOperation.mjs +2 -0
- package/esm2022/src/lib/models/WorkflowStage.mjs +2 -0
- package/esm2022/src/lib/models/actors.mjs +2 -0
- package/esm2022/src/lib/models/auth-mechanism.mjs +8 -0
- package/esm2022/src/lib/models/base.mjs +2 -0
- package/esm2022/src/lib/models/index.mjs +2 -0
- package/esm2022/src/lib/models/object-state.mjs +8 -0
- package/esm2022/src/lib/models/operation-type.mjs +7 -0
- package/esm2022/src/lib/models/paged.mjs +2 -0
- package/esm2022/src/lib/models/public-api.mjs +64 -0
- package/esm2022/src/lib/models/query-params.mjs +2 -0
- package/esm2022/src/lib/models/status.mjs +6 -0
- package/esm2022/src/lib/models/task-history.mjs +2 -0
- package/esm2022/src/lib/models/user-access-request-status.mjs +7 -0
- package/esm2022/src/lib/models/user.mjs +2 -0
- package/esm2022/src/lib/models/verben-workflow-ui-src-lib-models.mjs +5 -0
- package/esm2022/src/lib/pipes/async-label.pipe.mjs +25 -0
- package/esm2022/src/lib/pipes/index.mjs +2 -0
- package/esm2022/src/lib/pipes/public-api.mjs +2 -0
- package/esm2022/src/lib/pipes/verben-workflow-ui-src-lib-pipes.mjs +5 -0
- package/esm2022/src/lib/services/environment.service.mjs +26 -0
- package/esm2022/src/lib/services/http-web-request.service.mjs +92 -0
- package/esm2022/src/lib/services/index.mjs +2 -0
- package/esm2022/src/lib/services/label.service.mjs +134 -0
- package/esm2022/src/lib/services/public-api.mjs +5 -0
- package/esm2022/src/lib/services/util.service.mjs +73 -0
- package/esm2022/src/lib/services/verben-workflow-ui-src-lib-services.mjs +5 -0
- package/esm2022/src/lib/shared/base-table-style.mjs +55 -0
- package/esm2022/src/lib/shared/components/base-data-view.component.mjs +154 -0
- package/esm2022/src/lib/shared/components/base-model-field.mjs +21 -0
- package/esm2022/src/lib/shared/index.mjs +7 -0
- package/esm2022/src/lib/shared/models/DataViewConfig.mjs +2 -0
- package/esm2022/src/lib/shared/public-api.mjs +13 -0
- package/esm2022/src/lib/shared/shared.module.mjs +103 -0
- package/esm2022/src/lib/shared/verben-workflow-ui-src-lib-shared.mjs +5 -0
- package/esm2022/verben-workflow-ui.mjs +5 -0
- package/fesm2022/verben-workflow-ui-src-lib-base.mjs +1055 -0
- package/fesm2022/verben-workflow-ui-src-lib-base.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-actors.mjs +484 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-actors.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-designer.mjs +3887 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-designer.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-expiration.mjs +72 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-expiration.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-file-render.mjs +83 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-file-render.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-file-upload.mjs +159 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-file-upload.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-flowable-status.mjs +430 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-flowable-status.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-form-control.mjs +232 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-form-control.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-form-group.mjs +1967 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-form-group.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-form-response.mjs +769 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-form-response.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-form-timer.mjs +78 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-form-timer.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-form-viewer.mjs +118 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-form-viewer.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-forms.mjs +812 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-forms.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-journal.mjs +33 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-journal.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-my-queue.mjs +1317 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-my-queue.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-operation-popup.mjs +827 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-operation-popup.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-stage-details.mjs +72 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-stage-details.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-task-form.mjs +94 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-task-form.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-task-history.mjs +269 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-task-history.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-task-notification.mjs +995 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-task-notification.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-tasks.mjs +1046 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-tasks.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-wf.mjs +203 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-wf.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-workflow-designer.mjs +5353 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-workflow-designer.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-workflow-stage.mjs +412 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-workflow-stage.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-workflow.mjs +365 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-workflow.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-workflows.mjs +666 -0
- package/fesm2022/verben-workflow-ui-src-lib-components-workflows.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-models.mjs +255 -0
- package/fesm2022/verben-workflow-ui-src-lib-models.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-pipes.mjs +32 -0
- package/fesm2022/verben-workflow-ui-src-lib-pipes.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-services.mjs +320 -0
- package/fesm2022/verben-workflow-ui-src-lib-services.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui-src-lib-shared.mjs +336 -0
- package/fesm2022/verben-workflow-ui-src-lib-shared.mjs.map +1 -0
- package/fesm2022/verben-workflow-ui.mjs +34 -0
- package/fesm2022/verben-workflow-ui.mjs.map +1 -0
- package/index.d.ts +5 -0
- package/package.json +193 -8
- package/public-api.d.ts +22 -0
- package/src/lib/base/core/base-data-page.facade.d.ts +138 -0
- package/src/lib/base/core/base-data-page.service.d.ts +61 -0
- package/src/lib/base/core/base-data-page.state.d.ts +73 -0
- package/src/lib/base/handlers/filter-handler.service.d.ts +34 -0
- package/src/lib/base/handlers/search-handler.service.d.ts +20 -0
- package/src/lib/base/handlers/sort-handler.service.d.ts +30 -0
- package/src/lib/base/models/api-payload.d.ts +2 -0
- package/src/lib/base/models/page-config.interface.d.ts +24 -0
- package/src/lib/base/models/page-filter-tab-option.interface.d.ts +19 -0
- package/src/lib/base/public-api.d.ts +9 -0
- package/src/lib/base/utils/column-helpers.d.ts +24 -0
- package/src/lib/components/actors/actors.columns.d.ts +3 -0
- package/src/lib/components/actors/actors.component.d.ts +79 -0
- package/src/lib/components/actors/actors.config.d.ts +10 -0
- package/src/lib/components/actors/actors.facade.d.ts +29 -0
- package/src/lib/components/actors/actors.form.component.d.ts +23 -0
- package/src/lib/components/actors/actors.module.d.ts +11 -0
- package/src/lib/components/actors/actors.service.d.ts +33 -0
- package/src/lib/components/actors/actors.state.d.ts +19 -0
- package/src/lib/components/designer/components/label-editor.component.d.ts +22 -0
- package/src/lib/components/designer/components/node-selector.component.d.ts +23 -0
- package/src/lib/components/designer/components/swimlane-label.component.d.ts +12 -0
- package/src/lib/components/designer/components/swimlane-popup.component.d.ts +18 -0
- package/src/lib/components/designer/components/wf-canvas.component.d.ts +37 -0
- package/src/lib/components/designer/components/wf-designer.component.d.ts +22 -0
- package/src/lib/components/designer/components/wf-toolbar.component.d.ts +17 -0
- package/src/lib/components/designer/models/types.d.ts +103 -0
- package/src/lib/components/designer/services/canvas-state.service.d.ts +24 -0
- package/src/lib/components/designer/services/connection-segment-interaction.service.d.ts +36 -0
- package/src/lib/components/designer/services/connection.service.d.ts +47 -0
- package/src/lib/components/designer/services/keyboard-handler.service.d.ts +9 -0
- package/src/lib/components/designer/services/label-management.service.d.ts +14 -0
- package/src/lib/components/designer/services/node-finder.service.d.ts +10 -0
- package/src/lib/components/designer/services/node-interaction.service.d.ts +19 -0
- package/src/lib/components/designer/services/node-precondition.service.d.ts +37 -0
- package/src/lib/components/designer/services/node-selection.service.d.ts +19 -0
- package/src/lib/components/designer/services/orthogonal-router.service.d.ts +36 -0
- package/src/lib/components/designer/services/position-update.service.d.ts +10 -0
- package/src/lib/components/designer/services/rendering.service.d.ts +67 -0
- package/src/lib/components/designer/services/swimlane-management.service.d.ts +19 -0
- package/src/lib/components/designer/services/swimlane-stats.service.d.ts +19 -0
- package/src/lib/components/designer/services/viewport.service.d.ts +10 -0
- package/src/lib/components/designer/services/wf-facade.service.d.ts +67 -0
- package/src/lib/components/designer/services/wf-mapper.service.d.ts +26 -0
- package/src/lib/components/designer/services/wf-persistence.service.d.ts +21 -0
- package/src/lib/components/designer/services/wf-state.service.d.ts +30 -0
- package/src/lib/components/expiration/expiration.component.d.ts +20 -0
- package/src/lib/components/expiration/expiration.module.d.ts +9 -0
- package/src/lib/components/file-render/file-render.component.d.ts +17 -0
- package/src/lib/components/file-render/file-render.module.d.ts +10 -0
- package/src/lib/components/file-upload/file-upload.component.d.ts +22 -0
- package/src/lib/components/file-upload/file-upload.module.d.ts +11 -0
- package/src/lib/components/flowable-status/flowable-status.columns.d.ts +3 -0
- package/src/lib/components/flowable-status/flowable-status.component.d.ts +80 -0
- package/src/lib/components/flowable-status/flowable-status.config.d.ts +11 -0
- package/src/lib/components/flowable-status/flowable-status.facade.d.ts +26 -0
- package/src/lib/components/flowable-status/flowable-status.form.component.d.ts +18 -0
- package/src/lib/components/flowable-status/flowable-status.module.d.ts +11 -0
- package/src/lib/components/flowable-status/flowable-status.service.d.ts +23 -0
- package/src/lib/components/flowable-status/flowable-status.state.d.ts +11 -0
- package/src/lib/components/flowable-status/public-api.d.ts +2 -0
- package/src/lib/components/form-control/form-control.component.d.ts +38 -0
- package/src/lib/components/form-control/form-control.module.d.ts +11 -0
- package/src/lib/components/form-group/base-table-style.d.ts +1 -0
- package/src/lib/components/form-group/form-fields/form-fields.component.d.ts +136 -0
- package/src/lib/components/form-group/form-fields/form-fields.module.d.ts +11 -0
- package/src/lib/components/form-group/form-fields/form-fields.service.d.ts +9 -0
- package/src/lib/components/form-group/form-group.component.d.ts +108 -0
- package/src/lib/components/form-group/form-group.module.d.ts +15 -0
- package/src/lib/components/form-group/form-group.service.d.ts +9 -0
- package/src/lib/components/form-response/form-response.component.d.ts +108 -0
- package/src/lib/components/form-response/form-response.module.d.ts +12 -0
- package/src/lib/components/form-response/form-response.service.d.ts +9 -0
- package/src/lib/components/form-timer/form-timer.component.d.ts +13 -0
- package/src/lib/components/form-timer/form-timer.module.d.ts +9 -0
- package/src/lib/components/form-viewer/form-viewer.component.d.ts +17 -0
- package/src/lib/components/form-viewer/form-viewer.module.d.ts +11 -0
- package/src/lib/components/forms/base-table-style.d.ts +1 -0
- package/src/lib/components/forms/forms.component.d.ts +88 -0
- package/src/lib/components/forms/forms.module.d.ts +8 -0
- package/src/lib/components/forms/forms.service.d.ts +9 -0
- package/src/lib/components/journal/journal.component.d.ts +5 -0
- package/src/lib/components/journal/journal.module.d.ts +8 -0
- package/src/lib/components/my-queue/my-queue.columns.d.ts +3 -0
- package/src/lib/components/my-queue/my-queue.component.d.ts +58 -0
- package/src/lib/components/my-queue/my-queue.facade.d.ts +47 -0
- package/src/lib/components/my-queue/my-queue.module.d.ts +15 -0
- package/src/lib/components/my-queue/my-queue.service.d.ts +65 -0
- package/src/lib/components/my-queue/my-queue.state.d.ts +39 -0
- package/src/lib/components/my-queue/tasks.form.component.d.ts +43 -0
- package/src/lib/components/operation-popup/operation-popup.component.d.ts +62 -0
- package/src/lib/components/operation-popup/operation-popup.facade.d.ts +32 -0
- package/src/lib/components/operation-popup/operation-popup.service.d.ts +23 -0
- package/src/lib/components/operation-popup/operation-popup.state.d.ts +20 -0
- package/src/lib/components/stage-details/stage-details.component.d.ts +24 -0
- package/src/lib/components/stage-details/stage-details.module.d.ts +9 -0
- package/src/lib/components/task-form/task-form.component.d.ts +10 -0
- package/src/lib/components/task-form/task-form.module.d.ts +10 -0
- package/src/lib/components/task-history/task-history.component.d.ts +35 -0
- package/src/lib/components/task-history/task-history.module.d.ts +10 -0
- package/src/lib/components/task-history/task-history.service.d.ts +13 -0
- package/src/lib/components/task-notification/base-table-style.d.ts +1 -0
- package/src/lib/components/task-notification/task-notification.component.d.ts +89 -0
- package/src/lib/components/task-notification/task-notification.module.d.ts +8 -0
- package/src/lib/components/task-notification/task-notification.service.d.ts +32 -0
- package/src/lib/components/tasks/tasks.columns.d.ts +11 -0
- package/src/lib/components/tasks/tasks.component.d.ts +40 -0
- package/src/lib/components/tasks/tasks.facade.d.ts +44 -0
- package/src/lib/components/tasks/tasks.form.component.d.ts +40 -0
- package/src/lib/components/tasks/tasks.models.d.ts +4 -0
- package/src/lib/components/tasks/tasks.module.d.ts +17 -0
- package/src/lib/components/tasks/tasks.service.d.ts +58 -0
- package/src/lib/components/tasks/tasks.state.d.ts +46 -0
- package/src/lib/components/wf/wf.columns.d.ts +3 -0
- package/src/lib/components/wf/wf.component.d.ts +16 -0
- package/src/lib/components/wf/wf.module.d.ts +10 -0
- package/src/lib/components/wf/wf.service.d.ts +51 -0
- package/src/lib/components/workflow/column.d.ts +3 -0
- package/src/lib/components/workflow/helper.d.ts +2 -0
- package/src/lib/components/workflow/table-style.d.ts +1 -0
- package/src/lib/components/workflow/workflow.component.d.ts +57 -0
- package/src/lib/components/workflow/workflow.module.d.ts +9 -0
- package/src/lib/components/workflow-designer/action-dialog/action-dialog.component.d.ts +34 -0
- package/src/lib/components/workflow-designer/actor-tags-dialog/actor-tags-dialog.component.d.ts +25 -0
- package/src/lib/components/workflow-designer/conditions-popup/conditions-popup.component.d.ts +38 -0
- package/src/lib/components/workflow-designer/decision-popup/decision-popup.component.d.ts +29 -0
- package/src/lib/components/workflow-designer/designer-canvas/designer-canvas.component.d.ts +292 -0
- package/src/lib/components/workflow-designer/designer-toolbar/designer-toolbar.component.d.ts +39 -0
- package/src/lib/components/workflow-designer/designer-toolbar/designer-toolbar.types.d.ts +5 -0
- package/src/lib/components/workflow-designer/escalation-dialog/escalation-dialog.component.d.ts +46 -0
- package/src/lib/components/workflow-designer/services/connection.service.d.ts +101 -0
- package/src/lib/components/workflow-designer/services/node-management.service.d.ts +73 -0
- package/src/lib/components/workflow-designer/services/popup.service.d.ts +147 -0
- package/src/lib/components/workflow-designer/services/swimlane.service.d.ts +66 -0
- package/src/lib/components/workflow-designer/services/transformer.service.d.ts +51 -0
- package/src/lib/components/workflow-designer/stage-dialog/stage-dialog.component.d.ts +43 -0
- package/src/lib/components/workflow-designer/stage-node/stage-node.component.d.ts +58 -0
- package/src/lib/components/workflow-designer/swimlane-dialog/swimlane-dialog.component.d.ts +49 -0
- package/src/lib/components/workflow-designer/workflow-data.service.d.ts +59 -0
- package/src/lib/components/workflow-designer/workflow-designer.component.d.ts +121 -0
- package/src/lib/components/workflow-designer/workflow-designer.module.d.ts +41 -0
- package/src/lib/components/workflow-designer/workflow-designer.state.d.ts +278 -0
- package/src/lib/components/workflow-designer/workflow-designer.types.d.ts +129 -0
- package/src/lib/components/workflow-stage/workflow-stage.component.d.ts +78 -0
- package/src/lib/components/workflow-stage/workflow-stage.module.d.ts +12 -0
- package/src/lib/components/workflows/public-api.d.ts +4 -0
- package/src/lib/components/workflows/workflow-form/workflow-form.component.d.ts +28 -0
- package/src/lib/components/workflows/workflows.api.d.ts +38 -0
- package/src/lib/components/workflows/workflows.columns.d.ts +3 -0
- package/src/lib/components/workflows/workflows.component.d.ts +98 -0
- package/src/lib/components/workflows/workflows.config.d.ts +10 -0
- package/src/lib/components/workflows/workflows.facade.d.ts +41 -0
- package/src/lib/components/workflows/workflows.module.d.ts +11 -0
- package/src/lib/components/workflows/workflows.service.d.ts +32 -0
- package/src/lib/components/workflows/workflows.state.d.ts +15 -0
- package/src/lib/models/ActionHistory.d.ts +16 -0
- package/src/lib/models/ActionType.d.ts +9 -0
- package/src/lib/models/Actor.d.ts +11 -0
- package/src/lib/models/ActorTag.d.ts +6 -0
- package/src/lib/models/Coord.d.ts +4 -0
- package/src/lib/models/DataType.d.ts +25 -0
- package/src/lib/models/EAVEntity.d.ts +4 -0
- package/src/lib/models/ErrorResponse.d.ts +6 -0
- package/src/lib/models/Escalation.d.ts +14 -0
- package/src/lib/models/EscalationCycle.d.ts +12 -0
- package/src/lib/models/EscalationStage.d.ts +10 -0
- package/src/lib/models/EscalationType.d.ts +5 -0
- package/src/lib/models/File.d.ts +7 -0
- package/src/lib/models/FilterTypes.d.ts +6 -0
- package/src/lib/models/FlowableStatus.d.ts +5 -0
- package/src/lib/models/Form.d.ts +13 -0
- package/src/lib/models/FormEntity.d.ts +13 -0
- package/src/lib/models/FormFill.d.ts +15 -0
- package/src/lib/models/FormProperty.d.ts +15 -0
- package/src/lib/models/FormValues.d.ts +14 -0
- package/src/lib/models/MailConfig.d.ts +12 -0
- package/src/lib/models/MessageConfig.d.ts +3 -0
- package/src/lib/models/MessageMedium.d.ts +4 -0
- package/src/lib/models/OperationAction.d.ts +14 -0
- package/src/lib/models/PagedResult.d.ts +5 -0
- package/src/lib/models/PeriodMode.d.ts +10 -0
- package/src/lib/models/PermissionConfig.d.ts +7 -0
- package/src/lib/models/ReportSchedule.d.ts +22 -0
- package/src/lib/models/ReportType.d.ts +5 -0
- package/src/lib/models/Resource.d.ts +20 -0
- package/src/lib/models/ResponseKeyValue.d.ts +5 -0
- package/src/lib/models/SMSConfig.d.ts +10 -0
- package/src/lib/models/SearchDynamicWrapper.d.ts +5 -0
- package/src/lib/models/SearchOperator.d.ts +4 -0
- package/src/lib/models/SearchPropertySign.d.ts +9 -0
- package/src/lib/models/SearchPropertyValue.d.ts +12 -0
- package/src/lib/models/SearchPropertyValueType.d.ts +9 -0
- package/src/lib/models/Size.d.ts +4 -0
- package/src/lib/models/SortDirection.d.ts +5 -0
- package/src/lib/models/StageActorRule.d.ts +6 -0
- package/src/lib/models/SwimLane.d.ts +13 -0
- package/src/lib/models/Tag.d.ts +6 -0
- package/src/lib/models/Task.d.ts +31 -0
- package/src/lib/models/TaskAssignmentType.d.ts +4 -0
- package/src/lib/models/TaskNotification.d.ts +14 -0
- package/src/lib/models/TaskNotificationMessageType.d.ts +4 -0
- package/src/lib/models/TaskNotificationType.d.ts +6 -0
- package/src/lib/models/TaskStatus.d.ts +7 -0
- package/src/lib/models/Workflow.d.ts +21 -0
- package/src/lib/models/WorkflowAction.d.ts +13 -0
- package/src/lib/models/WorkflowOperation.d.ts +6 -0
- package/src/lib/models/WorkflowStage.d.ts +26 -0
- package/src/lib/models/actors.d.ts +8 -0
- package/src/lib/models/auth-mechanism.d.ts +13 -0
- package/src/lib/models/base.d.ts +13 -0
- package/src/lib/models/object-state.d.ts +6 -0
- package/src/lib/models/operation-type.d.ts +5 -0
- package/src/lib/models/paged.d.ts +9 -0
- package/src/lib/models/query-params.d.ts +8 -0
- package/src/lib/models/status.d.ts +4 -0
- package/src/lib/models/task-history.d.ts +17 -0
- package/src/lib/models/user-access-request-status.d.ts +5 -0
- package/src/lib/models/user.d.ts +24 -0
- package/src/lib/pipes/async-label.pipe.d.ts +11 -0
- package/src/lib/services/environment.service.d.ts +23 -0
- package/src/lib/services/http-web-request.service.d.ts +23 -0
- package/src/lib/services/label.service.d.ts +15 -0
- package/src/lib/services/public-api.d.ts +4 -0
- package/src/lib/services/util.service.d.ts +21 -0
- package/src/lib/shared/base-table-style.d.ts +2 -0
- package/src/lib/shared/components/base-data-view.component.d.ts +41 -0
- package/src/lib/shared/components/base-model-field.d.ts +26 -0
- package/src/lib/shared/models/DataViewConfig.d.ts +11 -0
- package/src/lib/shared/public-api.d.ts +5 -0
- package/src/lib/shared/shared.module.d.ts +11 -0
- package/ng-package.json +0 -15
- package/src/lib/base/core/base-data-page.facade.ts +0 -533
- package/src/lib/base/core/base-data-page.service.ts +0 -222
- package/src/lib/base/core/base-data-page.state.ts +0 -287
- package/src/lib/base/handlers/filter-handler.service.ts +0 -169
- package/src/lib/base/handlers/search-handler.service.ts +0 -33
- package/src/lib/base/handlers/sort-handler.service.ts +0 -93
- package/src/lib/base/models/api-payload.ts +0 -13
- package/src/lib/base/models/page-config.interface.ts +0 -49
- package/src/lib/base/models/page-filter-tab-option.interface.ts +0 -20
- package/src/lib/base/ng-package.json +0 -6
- package/src/lib/base/public-api.ts +0 -16
- package/src/lib/base/utils/column-helpers.ts +0 -77
- package/src/lib/components/actors/actors.columns.ts +0 -40
- package/src/lib/components/actors/actors.component.css +0 -0
- package/src/lib/components/actors/actors.component.html +0 -320
- package/src/lib/components/actors/actors.component.spec.ts +0 -23
- package/src/lib/components/actors/actors.component.ts +0 -221
- package/src/lib/components/actors/actors.config.ts +0 -55
- package/src/lib/components/actors/actors.facade.ts +0 -71
- package/src/lib/components/actors/actors.form.component.html +0 -37
- package/src/lib/components/actors/actors.form.component.ts +0 -69
- package/src/lib/components/actors/actors.model.ts +0 -4
- package/src/lib/components/actors/actors.module.ts +0 -13
- package/src/lib/components/actors/actors.service.ts +0 -85
- package/src/lib/components/actors/actors.state.ts +0 -31
- package/src/lib/components/actors/ng-package.json +0 -6
- package/src/lib/components/designer/components/label-editor.component.ts +0 -188
- package/src/lib/components/designer/components/node-selector.component.ts +0 -208
- package/src/lib/components/designer/components/swimlane-label.component.ts +0 -102
- package/src/lib/components/designer/components/swimlane-popup.component.ts +0 -51
- package/src/lib/components/designer/components/wf-canvas.component.ts +0 -495
- package/src/lib/components/designer/components/wf-designer.component.ts +0 -182
- package/src/lib/components/designer/components/wf-node.component.ts +0 -91
- package/src/lib/components/designer/components/wf-properties-popup.component.ts +0 -257
- package/src/lib/components/designer/components/wf-toolbar.component.ts +0 -84
- package/src/lib/components/designer/models/types.ts +0 -132
- package/src/lib/components/designer/ng-package.json +0 -6
- package/src/lib/components/designer/services/canvas-state.service.ts +0 -63
- package/src/lib/components/designer/services/connection-segment-interaction.service.ts +0 -141
- package/src/lib/components/designer/services/connection.service.ts +0 -350
- package/src/lib/components/designer/services/keyboard-handler.service.ts +0 -39
- package/src/lib/components/designer/services/label-management.service.ts +0 -72
- package/src/lib/components/designer/services/node-finder.service.ts +0 -34
- package/src/lib/components/designer/services/node-interaction.service.ts +0 -135
- package/src/lib/components/designer/services/node-placement.service.ts +0 -77
- package/src/lib/components/designer/services/node-precondition.service.ts +0 -138
- package/src/lib/components/designer/services/node-renderer.service.ts +0 -97
- package/src/lib/components/designer/services/node-selection.service.ts +0 -110
- package/src/lib/components/designer/services/orthogonal-router.service.ts +0 -233
- package/src/lib/components/designer/services/position-update.service.ts +0 -56
- package/src/lib/components/designer/services/rendering.service.ts +0 -296
- package/src/lib/components/designer/services/swimlane-management.service.ts +0 -189
- package/src/lib/components/designer/services/swimlane-stats.service.ts +0 -53
- package/src/lib/components/designer/services/tag-helper.service.ts +0 -80
- package/src/lib/components/designer/services/viewport.service.ts +0 -30
- package/src/lib/components/designer/services/wf-facade.service.ts +0 -287
- package/src/lib/components/designer/services/wf-mapper.service.ts +0 -447
- package/src/lib/components/designer/services/wf-persistence.service.ts +0 -184
- package/src/lib/components/designer/services/wf-state.service.ts +0 -143
- package/src/lib/components/expiration/expiration.component.css +0 -0
- package/src/lib/components/expiration/expiration.component.html +0 -21
- package/src/lib/components/expiration/expiration.component.spec.ts +0 -23
- package/src/lib/components/expiration/expiration.component.ts +0 -52
- package/src/lib/components/expiration/expiration.module.ts +0 -11
- package/src/lib/components/expiration/ng-package.json +0 -6
- package/src/lib/components/file-render/file-render.component.css +0 -4
- package/src/lib/components/file-render/file-render.component.html +0 -21
- package/src/lib/components/file-render/file-render.component.spec.ts +0 -23
- package/src/lib/components/file-render/file-render.component.ts +0 -34
- package/src/lib/components/file-render/file-render.module.ts +0 -19
- package/src/lib/components/file-render/ng-package.json +0 -6
- package/src/lib/components/file-upload/file-upload.component.css +0 -0
- package/src/lib/components/file-upload/file-upload.component.html +0 -69
- package/src/lib/components/file-upload/file-upload.component.spec.ts +0 -23
- package/src/lib/components/file-upload/file-upload.component.ts +0 -87
- package/src/lib/components/file-upload/file-upload.module.ts +0 -40
- package/src/lib/components/file-upload/ng-package.json +0 -6
- package/src/lib/components/flowable-status/flowable-status.columns.ts +0 -23
- package/src/lib/components/flowable-status/flowable-status.component.css +0 -1
- package/src/lib/components/flowable-status/flowable-status.component.html +0 -166
- package/src/lib/components/flowable-status/flowable-status.component.ts +0 -247
- package/src/lib/components/flowable-status/flowable-status.config.ts +0 -54
- package/src/lib/components/flowable-status/flowable-status.facade.ts +0 -70
- package/src/lib/components/flowable-status/flowable-status.form.component.html +0 -13
- package/src/lib/components/flowable-status/flowable-status.form.component.ts +0 -51
- package/src/lib/components/flowable-status/flowable-status.model.ts +0 -3
- package/src/lib/components/flowable-status/flowable-status.module.ts +0 -13
- package/src/lib/components/flowable-status/flowable-status.service.ts +0 -39
- package/src/lib/components/flowable-status/flowable-status.state.ts +0 -10
- package/src/lib/components/flowable-status/ng-package.json +0 -6
- package/src/lib/components/flowable-status/public-api.ts +0 -3
- package/src/lib/components/form-control/form-control.component.css +0 -0
- package/src/lib/components/form-control/form-control.component.html +0 -254
- package/src/lib/components/form-control/form-control.component.spec.ts +0 -23
- package/src/lib/components/form-control/form-control.component.ts +0 -169
- package/src/lib/components/form-control/form-control.module.ts +0 -47
- package/src/lib/components/form-control/ng-package.json +0 -6
- package/src/lib/components/form-group/base-table-style.ts +0 -52
- package/src/lib/components/form-group/form-fields/form-fields.component.css +0 -114
- package/src/lib/components/form-group/form-fields/form-fields.component.html +0 -621
- package/src/lib/components/form-group/form-fields/form-fields.component.spec.ts +0 -23
- package/src/lib/components/form-group/form-fields/form-fields.component.ts +0 -1115
- package/src/lib/components/form-group/form-fields/form-fields.module.ts +0 -48
- package/src/lib/components/form-group/form-fields/form-fields.service.ts +0 -70
- package/src/lib/components/form-group/form-fields/helper.ts +0 -45
- package/src/lib/components/form-group/form-group.component.css +0 -113
- package/src/lib/components/form-group/form-group.component.html +0 -486
- package/src/lib/components/form-group/form-group.component.spec.ts +0 -22
- package/src/lib/components/form-group/form-group.component.ts +0 -791
- package/src/lib/components/form-group/form-group.module.ts +0 -54
- package/src/lib/components/form-group/form-group.service.ts +0 -53
- package/src/lib/components/form-group/helper.ts +0 -45
- package/src/lib/components/form-group/ng-package.json +0 -6
- package/src/lib/components/form-response/form-response.component.css +0 -114
- package/src/lib/components/form-response/form-response.component.html +0 -188
- package/src/lib/components/form-response/form-response.component.spec.ts +0 -23
- package/src/lib/components/form-response/form-response.component.ts +0 -723
- package/src/lib/components/form-response/form-response.module.ts +0 -48
- package/src/lib/components/form-response/form-response.service.ts +0 -52
- package/src/lib/components/form-response/helper.ts +0 -222
- package/src/lib/components/form-response/ng-package.json +0 -6
- package/src/lib/components/form-timer/form-timer.component.css +0 -0
- package/src/lib/components/form-timer/form-timer.component.html +0 -47
- package/src/lib/components/form-timer/form-timer.component.spec.ts +0 -23
- package/src/lib/components/form-timer/form-timer.component.ts +0 -50
- package/src/lib/components/form-timer/form-timer.module.ts +0 -19
- package/src/lib/components/form-timer/ng-package.json +0 -6
- package/src/lib/components/form-viewer/form-viewer.component.css +0 -4
- package/src/lib/components/form-viewer/form-viewer.component.html +0 -62
- package/src/lib/components/form-viewer/form-viewer.component.spec.ts +0 -23
- package/src/lib/components/form-viewer/form-viewer.component.ts +0 -31
- package/src/lib/components/form-viewer/form-viewer.module.ts +0 -52
- package/src/lib/components/form-viewer/ng-package.json +0 -6
- package/src/lib/components/forms/base-table-style.ts +0 -52
- package/src/lib/components/forms/forms.component.css +0 -126
- package/src/lib/components/forms/forms.component.html +0 -538
- package/src/lib/components/forms/forms.component.spec.ts +0 -23
- package/src/lib/components/forms/forms.component.ts +0 -810
- package/src/lib/components/forms/forms.module.ts +0 -10
- package/src/lib/components/forms/forms.service.spec.ts +0 -16
- package/src/lib/components/forms/forms.service.ts +0 -65
- package/src/lib/components/forms/ng-package.json +0 -6
- package/src/lib/components/journal/journal.component.css +0 -0
- package/src/lib/components/journal/journal.component.html +0 -1
- package/src/lib/components/journal/journal.component.spec.ts +0 -23
- package/src/lib/components/journal/journal.component.ts +0 -10
- package/src/lib/components/journal/journal.module.ts +0 -10
- package/src/lib/components/journal/ng-package.json +0 -6
- package/src/lib/components/my-queue/my-queue.columns.ts +0 -37
- package/src/lib/components/my-queue/my-queue.component.css +0 -8
- package/src/lib/components/my-queue/my-queue.component.html +0 -319
- package/src/lib/components/my-queue/my-queue.component.spec.ts +0 -23
- package/src/lib/components/my-queue/my-queue.component.ts +0 -409
- package/src/lib/components/my-queue/my-queue.facade.ts +0 -670
- package/src/lib/components/my-queue/my-queue.helper.ts +0 -71
- package/src/lib/components/my-queue/my-queue.module.ts +0 -27
- package/src/lib/components/my-queue/my-queue.service.spec.ts +0 -16
- package/src/lib/components/my-queue/my-queue.service.ts +0 -262
- package/src/lib/components/my-queue/my-queue.state.ts +0 -133
- package/src/lib/components/my-queue/ng-package.json +0 -6
- package/src/lib/components/my-queue/tasks.form.component.html +0 -162
- package/src/lib/components/my-queue/tasks.form.component.ts +0 -179
- package/src/lib/components/operation-popup/ng-package.json +0 -6
- package/src/lib/components/operation-popup/operation-popup.component.css +0 -1
- package/src/lib/components/operation-popup/operation-popup.component.html +0 -107
- package/src/lib/components/operation-popup/operation-popup.component.ts +0 -476
- package/src/lib/components/operation-popup/operation-popup.facade.ts +0 -416
- package/src/lib/components/operation-popup/operation-popup.service.ts +0 -120
- package/src/lib/components/operation-popup/operation-popup.state.ts +0 -49
- package/src/lib/components/stage-details/ng-package.json +0 -6
- package/src/lib/components/stage-details/stage-details.component.css +0 -0
- package/src/lib/components/stage-details/stage-details.component.html +0 -95
- package/src/lib/components/stage-details/stage-details.component.spec.ts +0 -23
- package/src/lib/components/stage-details/stage-details.component.ts +0 -43
- package/src/lib/components/stage-details/stage-details.module.ts +0 -11
- package/src/lib/components/task-form/ng-package.json +0 -6
- package/src/lib/components/task-form/task-form.component.css +0 -0
- package/src/lib/components/task-form/task-form.component.html +0 -38
- package/src/lib/components/task-form/task-form.component.spec.ts +0 -23
- package/src/lib/components/task-form/task-form.component.ts +0 -15
- package/src/lib/components/task-form/task-form.module.ts +0 -31
- package/src/lib/components/task-history/ng-package.json +0 -6
- package/src/lib/components/task-history/task-history.component.css +0 -334
- package/src/lib/components/task-history/task-history.component.html +0 -145
- package/src/lib/components/task-history/task-history.component.spec.ts +0 -23
- package/src/lib/components/task-history/task-history.component.ts +0 -232
- package/src/lib/components/task-history/task-history.module.ts +0 -11
- package/src/lib/components/task-history/task-history.service.ts +0 -32
- package/src/lib/components/task-notification/base-table-style.ts +0 -52
- package/src/lib/components/task-notification/ng-package.json +0 -6
- package/src/lib/components/task-notification/task-notification.component.css +0 -94
- package/src/lib/components/task-notification/task-notification.component.html +0 -585
- package/src/lib/components/task-notification/task-notification.component.spec.ts +0 -23
- package/src/lib/components/task-notification/task-notification.component.ts +0 -770
- package/src/lib/components/task-notification/task-notification.module.ts +0 -10
- package/src/lib/components/task-notification/task-notification.service.spec.ts +0 -16
- package/src/lib/components/task-notification/task-notification.service.ts +0 -397
- package/src/lib/components/tasks/ng-package.json +0 -6
- package/src/lib/components/tasks/tasks.columns.ts +0 -50
- package/src/lib/components/tasks/tasks.component.css +0 -4
- package/src/lib/components/tasks/tasks.component.html +0 -385
- package/src/lib/components/tasks/tasks.component.spec.ts +0 -23
- package/src/lib/components/tasks/tasks.component.ts +0 -211
- package/src/lib/components/tasks/tasks.facade.ts +0 -482
- package/src/lib/components/tasks/tasks.form.component.html +0 -171
- package/src/lib/components/tasks/tasks.form.component.ts +0 -172
- package/src/lib/components/tasks/tasks.helper.ts +0 -71
- package/src/lib/components/tasks/tasks.models.ts +0 -4
- package/src/lib/components/tasks/tasks.module.ts +0 -29
- package/src/lib/components/tasks/tasks.service.spec.ts +0 -16
- package/src/lib/components/tasks/tasks.service.ts +0 -215
- package/src/lib/components/tasks/tasks.state.ts +0 -144
- package/src/lib/components/wf/ng-package.json +0 -6
- package/src/lib/components/wf/wf.columns.ts +0 -36
- package/src/lib/components/wf/wf.component.css +0 -0
- package/src/lib/components/wf/wf.component.html +0 -35
- package/src/lib/components/wf/wf.component.spec.ts +0 -23
- package/src/lib/components/wf/wf.component.ts +0 -71
- package/src/lib/components/wf/wf.facade.ts +0 -266
- package/src/lib/components/wf/wf.helper.ts +0 -23
- package/src/lib/components/wf/wf.module.ts +0 -14
- package/src/lib/components/wf/wf.service.spec.ts +0 -16
- package/src/lib/components/wf/wf.service.ts +0 -98
- package/src/lib/components/wf/wf.state.ts +0 -99
- package/src/lib/components/workflow/column.ts +0 -40
- package/src/lib/components/workflow/helper.ts +0 -53
- package/src/lib/components/workflow/ng-package.json +0 -6
- package/src/lib/components/workflow/table-style.ts +0 -53
- package/src/lib/components/workflow/workflow.component.css +0 -0
- package/src/lib/components/workflow/workflow.component.html +0 -226
- package/src/lib/components/workflow/workflow.component.spec.ts +0 -23
- package/src/lib/components/workflow/workflow.component.ts +0 -224
- package/src/lib/components/workflow/workflow.module.ts +0 -11
- package/src/lib/components/workflow-designer/action-dialog/action-dialog.component.css +0 -9
- package/src/lib/components/workflow-designer/action-dialog/action-dialog.component.html +0 -56
- package/src/lib/components/workflow-designer/action-dialog/action-dialog.component.spec.ts +0 -23
- package/src/lib/components/workflow-designer/action-dialog/action-dialog.component.ts +0 -142
- package/src/lib/components/workflow-designer/actor-tags-dialog/actor-tags-dialog.component.css +0 -0
- package/src/lib/components/workflow-designer/actor-tags-dialog/actor-tags-dialog.component.html +0 -45
- package/src/lib/components/workflow-designer/actor-tags-dialog/actor-tags-dialog.component.ts +0 -83
- package/src/lib/components/workflow-designer/conditions-popup/conditions-popup.component.css +0 -7
- package/src/lib/components/workflow-designer/conditions-popup/conditions-popup.component.html +0 -89
- package/src/lib/components/workflow-designer/conditions-popup/conditions-popup.component.spec.ts +0 -23
- package/src/lib/components/workflow-designer/conditions-popup/conditions-popup.component.ts +0 -87
- package/src/lib/components/workflow-designer/decision-popup/decision-popup.component.css +0 -11
- package/src/lib/components/workflow-designer/decision-popup/decision-popup.component.html +0 -74
- package/src/lib/components/workflow-designer/decision-popup/decision-popup.component.spec.ts +0 -23
- package/src/lib/components/workflow-designer/decision-popup/decision-popup.component.ts +0 -80
- package/src/lib/components/workflow-designer/designer-canvas/designer-canvas.component.css +0 -70
- package/src/lib/components/workflow-designer/designer-canvas/designer-canvas.component.html +0 -454
- package/src/lib/components/workflow-designer/designer-canvas/designer-canvas.component.spec.ts +0 -23
- package/src/lib/components/workflow-designer/designer-canvas/designer-canvas.component.ts +0 -1629
- package/src/lib/components/workflow-designer/designer-canvas/designer-canvas.connection-drop.spec.ts +0 -100
- package/src/lib/components/workflow-designer/designer-toolbar/designer-toolbar.component.css +0 -63
- package/src/lib/components/workflow-designer/designer-toolbar/designer-toolbar.component.html +0 -49
- package/src/lib/components/workflow-designer/designer-toolbar/designer-toolbar.component.spec.ts +0 -23
- package/src/lib/components/workflow-designer/designer-toolbar/designer-toolbar.component.ts +0 -86
- package/src/lib/components/workflow-designer/designer-toolbar/designer-toolbar.types.ts +0 -7
- package/src/lib/components/workflow-designer/docs/01-architecture.md +0 -145
- package/src/lib/components/workflow-designer/docs/02-coordinate-system.md +0 -171
- package/src/lib/components/workflow-designer/docs/03-data-model.md +0 -163
- package/src/lib/components/workflow-designer/docs/04-interactions.md +0 -156
- package/src/lib/components/workflow-designer/docs/05-persistence.md +0 -117
- package/src/lib/components/workflow-designer/docs/06-known-issues.md +0 -181
- package/src/lib/components/workflow-designer/docs/07-integration.md +0 -178
- package/src/lib/components/workflow-designer/docs/08-api-reference.md +0 -187
- package/src/lib/components/workflow-designer/docs/09-development.md +0 -141
- package/src/lib/components/workflow-designer/docs/README.md +0 -81
- package/src/lib/components/workflow-designer/escalation-dialog/escalation-dialog.component.css +0 -9
- package/src/lib/components/workflow-designer/escalation-dialog/escalation-dialog.component.html +0 -94
- package/src/lib/components/workflow-designer/escalation-dialog/escalation-dialog.component.spec.ts +0 -23
- package/src/lib/components/workflow-designer/escalation-dialog/escalation-dialog.component.ts +0 -273
- package/src/lib/components/workflow-designer/ng-package.json +0 -6
- package/src/lib/components/workflow-designer/services/connection.service.ts +0 -324
- package/src/lib/components/workflow-designer/services/node-management.service.ts +0 -372
- package/src/lib/components/workflow-designer/services/popup.service.ts +0 -276
- package/src/lib/components/workflow-designer/services/swimlane.service.ts +0 -176
- package/src/lib/components/workflow-designer/services/transformer.service.ts +0 -316
- package/src/lib/components/workflow-designer/stage-dialog/stage-dialog.component.css +0 -0
- package/src/lib/components/workflow-designer/stage-dialog/stage-dialog.component.html +0 -208
- package/src/lib/components/workflow-designer/stage-dialog/stage-dialog.component.spec.ts +0 -23
- package/src/lib/components/workflow-designer/stage-dialog/stage-dialog.component.ts +0 -194
- package/src/lib/components/workflow-designer/stage-node/stage-node.component.css +0 -15
- package/src/lib/components/workflow-designer/stage-node/stage-node.component.html +0 -93
- package/src/lib/components/workflow-designer/stage-node/stage-node.component.spec.ts +0 -23
- package/src/lib/components/workflow-designer/stage-node/stage-node.component.ts +0 -258
- package/src/lib/components/workflow-designer/swimlane-dialog/swimlane-dialog.component.css +0 -0
- package/src/lib/components/workflow-designer/swimlane-dialog/swimlane-dialog.component.html +0 -151
- package/src/lib/components/workflow-designer/swimlane-dialog/swimlane-dialog.component.spec.ts +0 -23
- package/src/lib/components/workflow-designer/swimlane-dialog/swimlane-dialog.component.ts +0 -156
- package/src/lib/components/workflow-designer/workflow-data.service.spec.ts +0 -16
- package/src/lib/components/workflow-designer/workflow-data.service.ts +0 -290
- package/src/lib/components/workflow-designer/workflow-designer.component.css +0 -59
- package/src/lib/components/workflow-designer/workflow-designer.component.html +0 -29
- package/src/lib/components/workflow-designer/workflow-designer.component.spec.ts +0 -23
- package/src/lib/components/workflow-designer/workflow-designer.component.ts +0 -553
- package/src/lib/components/workflow-designer/workflow-designer.models.ts +0 -114
- package/src/lib/components/workflow-designer/workflow-designer.module.ts +0 -88
- package/src/lib/components/workflow-designer/workflow-designer.state.ts +0 -1104
- package/src/lib/components/workflow-designer/workflow-designer.types.ts +0 -140
- package/src/lib/components/workflow-stage/ng-package.json +0 -6
- package/src/lib/components/workflow-stage/workflow-stage.component.css +0 -24
- package/src/lib/components/workflow-stage/workflow-stage.component.html +0 -339
- package/src/lib/components/workflow-stage/workflow-stage.component.spec.ts +0 -23
- package/src/lib/components/workflow-stage/workflow-stage.component.ts +0 -349
- package/src/lib/components/workflow-stage/workflow-stage.module.ts +0 -53
- package/src/lib/components/workflows/ng-package.json +0 -6
- package/src/lib/components/workflows/public-api.ts +0 -6
- package/src/lib/components/workflows/workflow-form/workflow-form.component.css +0 -0
- package/src/lib/components/workflows/workflow-form/workflow-form.component.html +0 -138
- package/src/lib/components/workflows/workflow-form/workflow-form.component.spec.ts +0 -23
- package/src/lib/components/workflows/workflow-form/workflow-form.component.ts +0 -85
- package/src/lib/components/workflows/workflows.api.ts +0 -117
- package/src/lib/components/workflows/workflows.columns.ts +0 -41
- package/src/lib/components/workflows/workflows.component.css +0 -4
- package/src/lib/components/workflows/workflows.component.html +0 -309
- package/src/lib/components/workflows/workflows.component.spec.ts +0 -23
- package/src/lib/components/workflows/workflows.component.ts +0 -303
- package/src/lib/components/workflows/workflows.config.ts +0 -58
- package/src/lib/components/workflows/workflows.facade.ts +0 -147
- package/src/lib/components/workflows/workflows.module.ts +0 -14
- package/src/lib/components/workflows/workflows.service.spec.ts +0 -16
- package/src/lib/components/workflows/workflows.service.ts +0 -88
- package/src/lib/components/workflows/workflows.state.ts +0 -21
- package/src/lib/models/ActionHistory.ts +0 -19
- package/src/lib/models/ActionType.ts +0 -9
- package/src/lib/models/Actor.ts +0 -12
- package/src/lib/models/ActorTag.ts +0 -8
- package/src/lib/models/Coord.ts +0 -4
- package/src/lib/models/DataType.ts +0 -25
- package/src/lib/models/EAVEntity.ts +0 -5
- package/src/lib/models/ErrorResponse.ts +0 -7
- package/src/lib/models/Escalation.ts +0 -15
- package/src/lib/models/EscalationCycle.ts +0 -13
- package/src/lib/models/EscalationStage.ts +0 -11
- package/src/lib/models/EscalationType.ts +0 -5
- package/src/lib/models/File.ts +0 -8
- package/src/lib/models/FilterTypes.ts +0 -8
- package/src/lib/models/FlowableStatus.ts +0 -6
- package/src/lib/models/Form.ts +0 -14
- package/src/lib/models/FormEntity.ts +0 -14
- package/src/lib/models/FormFill.ts +0 -16
- package/src/lib/models/FormProperty.ts +0 -16
- package/src/lib/models/FormValues.ts +0 -16
- package/src/lib/models/MailConfig.ts +0 -13
- package/src/lib/models/MessageConfig.ts +0 -5
- package/src/lib/models/MessageMedium.ts +0 -4
- package/src/lib/models/OperationAction.ts +0 -15
- package/src/lib/models/PagedResult.ts +0 -5
- package/src/lib/models/PeriodMode.ts +0 -10
- package/src/lib/models/PermissionConfig.ts +0 -8
- package/src/lib/models/ReportSchedule.ts +0 -23
- package/src/lib/models/ReportType.ts +0 -5
- package/src/lib/models/Resource.ts +0 -57
- package/src/lib/models/ResponseKeyValue.ts +0 -5
- package/src/lib/models/SMSConfig.ts +0 -11
- package/src/lib/models/SearchDynamicWrapper.ts +0 -6
- package/src/lib/models/SearchOperator.ts +0 -4
- package/src/lib/models/SearchPropertySign.ts +0 -9
- package/src/lib/models/SearchPropertyValue.ts +0 -13
- package/src/lib/models/SearchPropertyValueType.ts +0 -9
- package/src/lib/models/Size.ts +0 -4
- package/src/lib/models/SortDirection.ts +0 -5
- package/src/lib/models/StageActorRule.ts +0 -6
- package/src/lib/models/SwimLane.ts +0 -14
- package/src/lib/models/Tag.ts +0 -7
- package/src/lib/models/Task.ts +0 -32
- package/src/lib/models/TaskAssignmentType.ts +0 -4
- package/src/lib/models/TaskNotification.ts +0 -16
- package/src/lib/models/TaskNotificationMessageType.ts +0 -4
- package/src/lib/models/TaskNotificationType.ts +0 -6
- package/src/lib/models/TaskStatus.ts +0 -7
- package/src/lib/models/Workflow.ts +0 -22
- package/src/lib/models/WorkflowAction.ts +0 -14
- package/src/lib/models/WorkflowOperation.ts +0 -7
- package/src/lib/models/WorkflowStage.ts +0 -27
- package/src/lib/models/actors.ts +0 -10
- package/src/lib/models/auth-mechanism.ts +0 -14
- package/src/lib/models/base.ts +0 -14
- package/src/lib/models/ng-package.json +0 -6
- package/src/lib/models/object-state.ts +0 -6
- package/src/lib/models/operation-type.ts +0 -6
- package/src/lib/models/paged.ts +0 -9
- package/src/lib/models/query-params.ts +0 -9
- package/src/lib/models/status.ts +0 -5
- package/src/lib/models/task-history.ts +0 -14
- package/src/lib/models/user-access-request-status.ts +0 -5
- package/src/lib/models/user.ts +0 -25
- package/src/lib/pipes/async-label.pipe.spec.ts +0 -12
- package/src/lib/pipes/async-label.pipe.ts +0 -30
- package/src/lib/pipes/ng-package.json +0 -6
- package/src/lib/services/environment.service.spec.ts +0 -16
- package/src/lib/services/environment.service.ts +0 -31
- package/src/lib/services/http-web-request.service.spec.ts +0 -16
- package/src/lib/services/http-web-request.service.ts +0 -154
- package/src/lib/services/label.service.spec.ts +0 -16
- package/src/lib/services/label.service.ts +0 -182
- package/src/lib/services/ng-package.json +0 -6
- package/src/lib/services/public-api.ts +0 -5
- package/src/lib/services/util.service.spec.ts +0 -16
- package/src/lib/services/util.service.ts +0 -72
- package/src/lib/shared/base-table-style.ts +0 -56
- package/src/lib/shared/components/base-data-view.component.ts +0 -187
- package/src/lib/shared/components/base-model-field.ts +0 -31
- package/src/lib/shared/models/DataViewConfig.ts +0 -19
- package/src/lib/shared/ng-package.json +0 -6
- package/src/lib/shared/public-api.ts +0 -14
- package/src/lib/shared/shared.module.ts +0 -67
- package/src/lib/utils/index.ts +0 -1
- package/src/lib/utils/public-api.ts +0 -2
- package/src/lib/utils/store.ts +0 -50
- package/src/public-api.ts +0 -56
- package/src/styles.css +0 -96
- package/tailwind.config copy.js +0 -33
- package/tailwind.config.js +0 -20
- package/tsconfig.lib.json +0 -15
- package/tsconfig.lib.prod.json +0 -11
- package/tsconfig.spec.json +0 -15
- /package/src/lib/base/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/actors/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/actors/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/designer/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/designer/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/expiration/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/expiration/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/file-render/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/file-render/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/file-upload/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/file-upload/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/flowable-status/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/form-control/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/form-control/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/form-group/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/form-group/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/form-response/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/form-response/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/form-timer/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/form-timer/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/form-viewer/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/form-viewer/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/forms/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/forms/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/journal/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/journal/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/my-queue/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/my-queue/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/operation-popup/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/operation-popup/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/stage-details/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/stage-details/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/task-form/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/task-form/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/task-history/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/task-history/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/task-notification/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/task-notification/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/tasks/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/tasks/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/wf/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/wf/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/workflow/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/workflow/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/workflow-designer/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/workflow-designer/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/workflow-stage/{index.ts → index.d.ts} +0 -0
- /package/src/lib/components/workflow-stage/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/components/workflows/{index.ts → index.d.ts} +0 -0
- /package/src/lib/models/{index.ts → index.d.ts} +0 -0
- /package/src/lib/models/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/pipes/{index.ts → index.d.ts} +0 -0
- /package/src/lib/pipes/{public-api.ts → public-api.d.ts} +0 -0
- /package/src/lib/services/{index.ts → index.d.ts} +0 -0
- /package/src/lib/shared/{index.ts → index.d.ts} +0 -0
- /package/{src/styles → styles}/styles.css +0 -0
|
@@ -1,1629 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
Component,
|
|
3
|
-
ElementRef,
|
|
4
|
-
EventEmitter,
|
|
5
|
-
HostListener,
|
|
6
|
-
Input,
|
|
7
|
-
OnInit,
|
|
8
|
-
Output,
|
|
9
|
-
signal,
|
|
10
|
-
ViewChild,
|
|
11
|
-
WritableSignal,
|
|
12
|
-
} from '@angular/core';
|
|
13
|
-
import { EscalationType, Form, Workflow, WorkflowAction, WorkflowStage } from 'verben-workflow-ui/src/lib/models';
|
|
14
|
-
import { WorkflowDataService } from '../workflow-data.service';
|
|
15
|
-
import { WorkflowDesignerState } from '../workflow-designer.state';
|
|
16
|
-
import {
|
|
17
|
-
Connection,
|
|
18
|
-
ConnectionPoint,
|
|
19
|
-
Node,
|
|
20
|
-
SwimlaneItem,
|
|
21
|
-
ToolType,
|
|
22
|
-
Node as WFNode,
|
|
23
|
-
} from '../workflow-designer.types';
|
|
24
|
-
|
|
25
|
-
/**
|
|
26
|
-
* The SVG editing surface. Renders the entire scene — swimlanes, nodes,
|
|
27
|
-
* connections, and overlaid popups — from {@link WorkflowDesignerState}, and
|
|
28
|
-
* owns nearly all pointer interaction: placing nodes, dragging them within and
|
|
29
|
-
* between lanes, and the connection drag/drop pipeline.
|
|
30
|
-
*
|
|
31
|
-
* This is the largest file in the module. It reads and mutates the shared
|
|
32
|
-
* `state` singleton directly rather than holding its own model.
|
|
33
|
-
*
|
|
34
|
-
* ## Coordinate spaces used here
|
|
35
|
-
*
|
|
36
|
-
* - {@link getMousePosition} returns **absolute canvas** coordinates — the space
|
|
37
|
-
* `state.addNode` and `Math.floor(y / 263)` expect.
|
|
38
|
-
* - {@link getViewportPosition} additionally subtracts scroll offsets and is
|
|
39
|
-
* used **only** to position HTML popups over the SVG. Never feed its output
|
|
40
|
-
* into node or connection math.
|
|
41
|
-
*
|
|
42
|
-
* Read `../docs/02-coordinate-system.md` before changing anything positional.
|
|
43
|
-
*
|
|
44
|
-
* ## Popups
|
|
45
|
-
*
|
|
46
|
-
* Popup visibility is tracked with local booleans here, even though a
|
|
47
|
-
* `PopupService` exists. Only `StageDialogComponent` uses that service; the two
|
|
48
|
-
* mechanisms coexist. See `../docs/06-known-issues.md` section C.
|
|
49
|
-
*
|
|
50
|
-
* @see ../docs/04-interactions.md — the user-facing flows this component implements
|
|
51
|
-
*/
|
|
52
|
-
@Component({
|
|
53
|
-
selector: 'lib-designer-canvas',
|
|
54
|
-
templateUrl: './designer-canvas.component.html',
|
|
55
|
-
styleUrl: './designer-canvas.component.css',
|
|
56
|
-
})
|
|
57
|
-
export class DesignerCanvasComponent implements OnInit {
|
|
58
|
-
/** Active toolbar tool; `null` means pointer mode. */
|
|
59
|
-
@Input() selectedTool: ToolType = null;
|
|
60
|
-
/**
|
|
61
|
-
* Canvas click position in **absolute** coordinates, for the parent to act on
|
|
62
|
-
* per the selected tool.
|
|
63
|
-
*
|
|
64
|
-
* Also carries a sentinel: `{ x: -1, y: laneIndex }` means "edit the swimlane
|
|
65
|
-
* at `laneIndex`" (the lane's pencil button), not a placement.
|
|
66
|
-
*/
|
|
67
|
-
@Output() clickedPosition = new EventEmitter<{ x: number; y: number }>();
|
|
68
|
-
/** Emitted when a workflow is chosen for a subflow node. */
|
|
69
|
-
@Output() subflowSelected = new EventEmitter();
|
|
70
|
-
/** Where a stage will be created once the stage dialog is confirmed. */
|
|
71
|
-
pendingStagePosition: { swimlaneIndex: number; x: number; y: number } | null =
|
|
72
|
-
null;
|
|
73
|
-
/** A stage node's properties were edited on the canvas. */
|
|
74
|
-
@Output() stagePropertiesUpdated = new EventEmitter<{
|
|
75
|
-
nodeId: string;
|
|
76
|
-
stageData: Partial<WorkflowStage>;
|
|
77
|
-
}>();
|
|
78
|
-
/** A connection's action properties were edited on the canvas. */
|
|
79
|
-
@Output() actionPropertiesUpdated = new EventEmitter<{
|
|
80
|
-
connectionId: string;
|
|
81
|
-
actionData: Partial<WorkflowAction>;
|
|
82
|
-
}>();
|
|
83
|
-
|
|
84
|
-
/** The SVG root; its bounding box defines absolute canvas space. */
|
|
85
|
-
@ViewChild('canvas', { static: true }) canvasRef!: ElementRef<SVGElement>;
|
|
86
|
-
|
|
87
|
-
@HostListener('window:mouseup', ['$event'])
|
|
88
|
-
onWindowMouseUp(event: MouseEvent): void {
|
|
89
|
-
// If we have a popup open but the mouse is released outside, clean up
|
|
90
|
-
if (
|
|
91
|
-
!this.showSubflowPopup &&
|
|
92
|
-
!this.showStartNodeFormPopup &&
|
|
93
|
-
!this.popupVisible && // Only end drag if no popup is visible
|
|
94
|
-
this.state.isConnectionDragging()
|
|
95
|
-
) {
|
|
96
|
-
this.state.endConnectionDrag();
|
|
97
|
-
}
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
// Canvas dimensions
|
|
101
|
-
canvasWidth = 3000;
|
|
102
|
-
canvasHeight = 2000;
|
|
103
|
-
|
|
104
|
-
// Grid size
|
|
105
|
-
gridSize = 20;
|
|
106
|
-
|
|
107
|
-
swimlaneHeight = 263;
|
|
108
|
-
visibleConnectionPointsNodeId: string | null = null;
|
|
109
|
-
popupVisible = false;
|
|
110
|
-
popupX = 0;
|
|
111
|
-
popupY = 0;
|
|
112
|
-
allowedNodeTypes: string[] = [];
|
|
113
|
-
|
|
114
|
-
showStartNodeFormPopup: boolean = false;
|
|
115
|
-
startNodeFormsList: Form[] = [];
|
|
116
|
-
isLoadingStartNodeForms: boolean = false;
|
|
117
|
-
startNodeFormPopupX: number = 0;
|
|
118
|
-
startNodeFormPopupY: number = 0;
|
|
119
|
-
activeNodeForFormSelection: Node | null = null;
|
|
120
|
-
nodeForms: WritableSignal<
|
|
121
|
-
Record<string, { formId: string; formName: string }>
|
|
122
|
-
> = signal({});
|
|
123
|
-
|
|
124
|
-
showSubflowPopup: boolean = false;
|
|
125
|
-
workflowsList: Workflow[] = [];
|
|
126
|
-
isLoadingWorkflows: boolean = false;
|
|
127
|
-
subflowPopupX: number = 0;
|
|
128
|
-
subflowPopupY: number = 0;
|
|
129
|
-
pendingSubflowPosition: {
|
|
130
|
-
swimlaneIndex: number;
|
|
131
|
-
x: number;
|
|
132
|
-
y: number;
|
|
133
|
-
} | null = null;
|
|
134
|
-
|
|
135
|
-
pendingDecisionConnection: {
|
|
136
|
-
decisionNodeId: string;
|
|
137
|
-
swimlaneIndex: number;
|
|
138
|
-
x: number;
|
|
139
|
-
y: number;
|
|
140
|
-
} | null = null;
|
|
141
|
-
|
|
142
|
-
pendingConnectionSourcePoint: ConnectionPoint | null = null;
|
|
143
|
-
pendingConnectionSourceSwimlaneIndex: number | null = null;
|
|
144
|
-
|
|
145
|
-
// ─── Node-drag state ───────────────────────────────────────────────────────
|
|
146
|
-
isDraggingNode = false;
|
|
147
|
-
draggingNode: Node | null = null;
|
|
148
|
-
private draggingNodeSwimlaneIndex: number = -1;
|
|
149
|
-
/** Mouse offset relative to node top-left at drag start (absolute canvas coords). */
|
|
150
|
-
private dragOffsetX = 0;
|
|
151
|
-
private dragOffsetY = 0;
|
|
152
|
-
|
|
153
|
-
showDecisionConditionDialog: boolean = false;
|
|
154
|
-
showConditionsDialog: boolean = false;
|
|
155
|
-
activeDecisionNodeId: string = '';
|
|
156
|
-
activeConnectionId: string = '';
|
|
157
|
-
decisionConditionPopupX: number = 0;
|
|
158
|
-
decisionConditionPopupY: number = 0;
|
|
159
|
-
|
|
160
|
-
isCreatingStageFromDecision: boolean = false;
|
|
161
|
-
pendingDecisionCondition: string = '';
|
|
162
|
-
activeStageId: string | null = null;
|
|
163
|
-
activeActionId: string | null = null;
|
|
164
|
-
|
|
165
|
-
showStageDialogLocal: boolean = false;
|
|
166
|
-
showEscalationDialogLocal: boolean = false;
|
|
167
|
-
activeEscalationType: WritableSignal<EscalationType | null> = signal(null);
|
|
168
|
-
activeStageCode: WritableSignal<string | null> = signal(null);
|
|
169
|
-
activeStageData: Partial<WorkflowStage> = {};
|
|
170
|
-
activeActionData: Connection | null = null;
|
|
171
|
-
|
|
172
|
-
showActionDialogLocal: boolean = false;
|
|
173
|
-
|
|
174
|
-
potentialTargetPointId: string | null = null;
|
|
175
|
-
|
|
176
|
-
constructor(
|
|
177
|
-
public state: WorkflowDesignerState,
|
|
178
|
-
private dataService: WorkflowDataService
|
|
179
|
-
) { }
|
|
180
|
-
|
|
181
|
-
ngOnInit(): void {
|
|
182
|
-
this.updateCanvasSize();
|
|
183
|
-
}
|
|
184
|
-
|
|
185
|
-
// Handle mouse click on canvas
|
|
186
|
-
onCanvasClick(event: MouseEvent): void {
|
|
187
|
-
// Only process canvas clicks if a tool is selected
|
|
188
|
-
if (!this.selectedTool) {
|
|
189
|
-
return;
|
|
190
|
-
}
|
|
191
|
-
|
|
192
|
-
// Get the position where the click occurred
|
|
193
|
-
const position = this.getMousePosition(event);
|
|
194
|
-
|
|
195
|
-
// Calculate the swimlane index based on position
|
|
196
|
-
// const swimlaneIndex = Math.floor(position.y / this.swimlaneHeight);
|
|
197
|
-
|
|
198
|
-
// Only emit the position if we have a tool selected and it's a valid click area
|
|
199
|
-
if (this.selectedTool) {
|
|
200
|
-
this.clickedPosition.emit({
|
|
201
|
-
x: position.x,
|
|
202
|
-
y: position.y,
|
|
203
|
-
});
|
|
204
|
-
}
|
|
205
|
-
}
|
|
206
|
-
|
|
207
|
-
onShowShieldDialog(stageId: string): void {
|
|
208
|
-
// Find the node
|
|
209
|
-
const nodeInfo = this.state.findNodeById(stageId);
|
|
210
|
-
if (nodeInfo) {
|
|
211
|
-
this.activeStageId = stageId;
|
|
212
|
-
// Seed the entry-point toggle from the node's actual start state, which is
|
|
213
|
-
// the source of truth for the start circle and API serialization. The
|
|
214
|
-
// auto-assigned entry node has isStartNode=true without stageData.IsEntryPoint.
|
|
215
|
-
this.activeStageData = {
|
|
216
|
-
...nodeInfo.node.stageData,
|
|
217
|
-
IsEntryPoint: nodeInfo.node.isStartNode,
|
|
218
|
-
id: stageId,
|
|
219
|
-
};
|
|
220
|
-
this.showStageDialogLocal = true;
|
|
221
|
-
}
|
|
222
|
-
}
|
|
223
|
-
|
|
224
|
-
onShowActionDialog(connectionInfo: Connection): void {
|
|
225
|
-
// Find the node
|
|
226
|
-
// const connectionInfo = this.state.findActionById(actionId);
|
|
227
|
-
if (connectionInfo) {
|
|
228
|
-
this.activeActionId = connectionInfo.id;
|
|
229
|
-
this.activeActionData = connectionInfo;
|
|
230
|
-
this.showActionDialogLocal = true;
|
|
231
|
-
}
|
|
232
|
-
}
|
|
233
|
-
|
|
234
|
-
onShowEscalationDialog(event: {
|
|
235
|
-
stageId: string;
|
|
236
|
-
type: EscalationType;
|
|
237
|
-
}): void {
|
|
238
|
-
// Find the node
|
|
239
|
-
const nodeInfo = this.state.findNodeById(event.stageId);
|
|
240
|
-
if (nodeInfo) {
|
|
241
|
-
this.activeStageId = event.stageId;
|
|
242
|
-
this.activeStageData = nodeInfo.node.stageData || {
|
|
243
|
-
id: this.activeStageId,
|
|
244
|
-
};
|
|
245
|
-
this.activeEscalationType.set(event.type);
|
|
246
|
-
this.activeStageCode.set(this.activeStageData?.Code || '');
|
|
247
|
-
this.showEscalationDialogLocal = true;
|
|
248
|
-
}
|
|
249
|
-
}
|
|
250
|
-
|
|
251
|
-
// Add this method to handle dialog closure
|
|
252
|
-
onStageDialogClosed(): void {
|
|
253
|
-
this.showStageDialogLocal = false;
|
|
254
|
-
this.activeStageId = null;
|
|
255
|
-
this.activeStageData = {};
|
|
256
|
-
}
|
|
257
|
-
|
|
258
|
-
onActionDialogClosed(): void {
|
|
259
|
-
this.showActionDialogLocal = false;
|
|
260
|
-
this.activeActionId = null;
|
|
261
|
-
this.activeActionData = null;
|
|
262
|
-
}
|
|
263
|
-
|
|
264
|
-
onActionDialogDeleted(connectionId: string): void {
|
|
265
|
-
// Remove the connection from state
|
|
266
|
-
this.state.connections = this.state.connections.filter(
|
|
267
|
-
(c) => c.id !== connectionId
|
|
268
|
-
);
|
|
269
|
-
// Close the dialog
|
|
270
|
-
this.onActionDialogClosed();
|
|
271
|
-
}
|
|
272
|
-
|
|
273
|
-
// Add this method to handle dialog closure
|
|
274
|
-
onEscalationDialogClosed(): void {
|
|
275
|
-
this.showEscalationDialogLocal = false;
|
|
276
|
-
this.activeStageId = null;
|
|
277
|
-
this.activeEscalationType.set(null);
|
|
278
|
-
this.activeStageCode.set(null);
|
|
279
|
-
this.activeStageData = {};
|
|
280
|
-
}
|
|
281
|
-
|
|
282
|
-
// Add this method to handle saving stage data
|
|
283
|
-
onStageDialogSaved(stageData: Partial<WorkflowStage>): void {
|
|
284
|
-
if (this.activeStageId) {
|
|
285
|
-
// Editing an existing stage
|
|
286
|
-
const nodeInfo = this.state.findNodeById(this.activeStageId);
|
|
287
|
-
if (nodeInfo) {
|
|
288
|
-
// Update the stage data
|
|
289
|
-
nodeInfo.node.stageData = {
|
|
290
|
-
...nodeInfo.node.stageData,
|
|
291
|
-
...stageData,
|
|
292
|
-
};
|
|
293
|
-
|
|
294
|
-
// Sync the entry-point flag onto node.isStartNode, which drives both the
|
|
295
|
-
// start circle and the IsEntryPoint value serialized to the API.
|
|
296
|
-
if (stageData.IsEntryPoint) {
|
|
297
|
-
// Enforce a single entry point: this node becomes the sole start node.
|
|
298
|
-
this.state.swimlanes.forEach((swimlane) => {
|
|
299
|
-
swimlane.nodes?.forEach((node) => {
|
|
300
|
-
node.isStartNode = node.id === this.activeStageId;
|
|
301
|
-
});
|
|
302
|
-
});
|
|
303
|
-
this.state.startNodeId = this.activeStageId;
|
|
304
|
-
} else {
|
|
305
|
-
nodeInfo.node.isStartNode = false;
|
|
306
|
-
if (this.state.startNodeId === this.activeStageId) {
|
|
307
|
-
this.state.startNodeId = null;
|
|
308
|
-
}
|
|
309
|
-
}
|
|
310
|
-
|
|
311
|
-
// Emit event for parent component to know about the update
|
|
312
|
-
this.stagePropertiesUpdated.emit({
|
|
313
|
-
nodeId: this.activeStageId,
|
|
314
|
-
stageData: nodeInfo.node.stageData,
|
|
315
|
-
});
|
|
316
|
-
}
|
|
317
|
-
}
|
|
318
|
-
|
|
319
|
-
// Close the dialog
|
|
320
|
-
this.onStageDialogClosed();
|
|
321
|
-
}
|
|
322
|
-
|
|
323
|
-
onActionDialogSaved(actionData: Connection): void {
|
|
324
|
-
if (this.activeActionId) {
|
|
325
|
-
// Editing an existing stage
|
|
326
|
-
// let connectionInfo = this.state.findActionById(this.activeActionId);
|
|
327
|
-
this.state.connections = this.state.connections.map((connection, index) => {
|
|
328
|
-
if (connection.id === this.activeActionId) {
|
|
329
|
-
connection.label = actionData.label;
|
|
330
|
-
connection.action = actionData.action;
|
|
331
|
-
connection.targetStatus = actionData.targetStatus;
|
|
332
|
-
}
|
|
333
|
-
return connection;
|
|
334
|
-
})
|
|
335
|
-
}
|
|
336
|
-
|
|
337
|
-
// Close the dialog
|
|
338
|
-
this.onActionDialogClosed();
|
|
339
|
-
}
|
|
340
|
-
|
|
341
|
-
updateCanvasSize(): void {
|
|
342
|
-
const requiredHeight =
|
|
343
|
-
(this.state.swimlanes.length + 1) * this.swimlaneHeight;
|
|
344
|
-
this.canvasHeight = Math.max(2000, requiredHeight); // Ensure we have at least our default height
|
|
345
|
-
|
|
346
|
-
// Update all the swimlane clip paths when size changes
|
|
347
|
-
setTimeout(() => {
|
|
348
|
-
this.state.swimlanes.forEach((swimlane, index) => {
|
|
349
|
-
const clipPathId = `swimlane-clip-${index}`;
|
|
350
|
-
const clipPathElement = document.getElementById(clipPathId);
|
|
351
|
-
if (clipPathElement) {
|
|
352
|
-
const rectElement = clipPathElement.querySelector('rect');
|
|
353
|
-
if (rectElement) {
|
|
354
|
-
rectElement.setAttribute('width', this.canvasWidth.toString());
|
|
355
|
-
}
|
|
356
|
-
}
|
|
357
|
-
});
|
|
358
|
-
}, 0);
|
|
359
|
-
}
|
|
360
|
-
|
|
361
|
-
/**
|
|
362
|
-
* Converts a DOM mouse event into **absolute canvas coordinates**, relative
|
|
363
|
-
* to the SVG's bounding box.
|
|
364
|
-
*
|
|
365
|
-
* This is the space that `state.addNode`, `Math.floor(y / 263)`, and all
|
|
366
|
-
* connection math expect. Use this — not {@link getViewportPosition} — for
|
|
367
|
-
* anything positional.
|
|
368
|
-
*/
|
|
369
|
-
private getMousePosition(event: MouseEvent): { x: number; y: number } {
|
|
370
|
-
// Use clientX/Y and getBoundingClientRect() for cross-browser compatibility
|
|
371
|
-
const rect = this.canvasRef.nativeElement.getBoundingClientRect();
|
|
372
|
-
return {
|
|
373
|
-
x: event.clientX - rect.left,
|
|
374
|
-
y: event.clientY - rect.top,
|
|
375
|
-
};
|
|
376
|
-
}
|
|
377
|
-
|
|
378
|
-
/**
|
|
379
|
-
* Converts absolute canvas coordinates into **viewport coordinates** by
|
|
380
|
-
* subtracting the scroll container's offsets.
|
|
381
|
-
*
|
|
382
|
-
* Used **only** to position HTML popups overlaid on the SVG. Feeding this
|
|
383
|
-
* into node or connection math produces elements that drift as the canvas
|
|
384
|
-
* scrolls.
|
|
385
|
-
*/
|
|
386
|
-
private getViewportPosition(canvasX: number, canvasY: number): { x: number; y: number } {
|
|
387
|
-
const parentElement = this.canvasRef.nativeElement.parentElement;
|
|
388
|
-
const scrollLeft = parentElement?.scrollLeft || 0;
|
|
389
|
-
const scrollTop = parentElement?.scrollTop || 0;
|
|
390
|
-
|
|
391
|
-
return {
|
|
392
|
-
x: canvasX - scrollLeft,
|
|
393
|
-
y: canvasY - scrollTop,
|
|
394
|
-
};
|
|
395
|
-
}
|
|
396
|
-
|
|
397
|
-
showConnectionPoints(nodeId: string, swimlaneIndex: number): void {
|
|
398
|
-
this.visibleConnectionPointsNodeId = nodeId;
|
|
399
|
-
}
|
|
400
|
-
|
|
401
|
-
isMouseOverNode(
|
|
402
|
-
event: MouseEvent,
|
|
403
|
-
node: WFNode,
|
|
404
|
-
swimlaneIndex: number
|
|
405
|
-
): boolean {
|
|
406
|
-
const position = this.getMousePosition(event);
|
|
407
|
-
const nodeBounds = this.getNodeBoundsWithPadding(node, swimlaneIndex);
|
|
408
|
-
|
|
409
|
-
return (
|
|
410
|
-
position.x >= nodeBounds.x &&
|
|
411
|
-
position.x <= nodeBounds.x + nodeBounds.width &&
|
|
412
|
-
position.y >= nodeBounds.y &&
|
|
413
|
-
position.y <= nodeBounds.y + nodeBounds.height
|
|
414
|
-
);
|
|
415
|
-
}
|
|
416
|
-
|
|
417
|
-
// helper method to calculate node bounds with padding
|
|
418
|
-
getNodeBoundsWithPadding(
|
|
419
|
-
node: WFNode,
|
|
420
|
-
swimlaneIndex: number
|
|
421
|
-
): { x: number; y: number; width: number; height: number } {
|
|
422
|
-
const padding = 10; // Add 10px padding around nodes for easier hover detection
|
|
423
|
-
|
|
424
|
-
// Calculate the absolute Y position including swimlane offset
|
|
425
|
-
const absoluteY = node.y + swimlaneIndex * 263;
|
|
426
|
-
|
|
427
|
-
return {
|
|
428
|
-
x: node.x - padding,
|
|
429
|
-
y: absoluteY - padding,
|
|
430
|
-
width: node.width + padding * 2,
|
|
431
|
-
height: node.height + padding * 2,
|
|
432
|
-
};
|
|
433
|
-
}
|
|
434
|
-
|
|
435
|
-
hideConnectionPoints(nodeId: string): void {
|
|
436
|
-
if (
|
|
437
|
-
this.visibleConnectionPointsNodeId === nodeId &&
|
|
438
|
-
!this.state.isConnectionDragging()
|
|
439
|
-
) {
|
|
440
|
-
this.visibleConnectionPointsNodeId = null;
|
|
441
|
-
}
|
|
442
|
-
}
|
|
443
|
-
|
|
444
|
-
isConnectionPointVisible(nodeId: string): boolean {
|
|
445
|
-
return this.visibleConnectionPointsNodeId === nodeId;
|
|
446
|
-
}
|
|
447
|
-
|
|
448
|
-
startConnectionDrag(
|
|
449
|
-
event: MouseEvent,
|
|
450
|
-
point: ConnectionPoint,
|
|
451
|
-
swimlaneIndex: number
|
|
452
|
-
): void {
|
|
453
|
-
event.preventDefault();
|
|
454
|
-
event.stopPropagation();
|
|
455
|
-
|
|
456
|
-
// Check if this is an exit point node
|
|
457
|
-
const nodeInfo = this.state.findNodeById(point.nodeId);
|
|
458
|
-
if (
|
|
459
|
-
nodeInfo &&
|
|
460
|
-
nodeInfo.node.type === 'stage' &&
|
|
461
|
-
nodeInfo.node.stageData?.IsExitPoint
|
|
462
|
-
) {
|
|
463
|
-
// Don't allow connections from exit points
|
|
464
|
-
return;
|
|
465
|
-
}
|
|
466
|
-
|
|
467
|
-
const position = this.getMousePosition(event);
|
|
468
|
-
this.state.startConnectionDrag(
|
|
469
|
-
point,
|
|
470
|
-
swimlaneIndex,
|
|
471
|
-
position.x,
|
|
472
|
-
position.y
|
|
473
|
-
);
|
|
474
|
-
|
|
475
|
-
// Add mouse move and mouse up event listeners to the document
|
|
476
|
-
document.addEventListener('mousemove', this.onMouseMove);
|
|
477
|
-
document.addEventListener('mouseup', this.onMouseUp);
|
|
478
|
-
}
|
|
479
|
-
|
|
480
|
-
highlightPotentialTargets(event: MouseEvent): void {
|
|
481
|
-
if (!this.state.isConnectionDragging()) return;
|
|
482
|
-
|
|
483
|
-
const position = this.getMousePosition(event);
|
|
484
|
-
const targetPointInfo = this.findConnectionPointAtPosition(
|
|
485
|
-
position.x,
|
|
486
|
-
position.y
|
|
487
|
-
);
|
|
488
|
-
|
|
489
|
-
if (
|
|
490
|
-
targetPointInfo &&
|
|
491
|
-
targetPointInfo.point.id !== this.potentialTargetPointId
|
|
492
|
-
) {
|
|
493
|
-
// We have a new target point
|
|
494
|
-
this.potentialTargetPointId = targetPointInfo.point.id;
|
|
495
|
-
} else if (!targetPointInfo && this.potentialTargetPointId) {
|
|
496
|
-
// We're no longer over a target point
|
|
497
|
-
this.potentialTargetPointId = null;
|
|
498
|
-
}
|
|
499
|
-
}
|
|
500
|
-
|
|
501
|
-
// ─────────────────────────────────────────────────────────────────────────
|
|
502
|
-
// Node drag logic
|
|
503
|
-
// ─────────────────────────────────────────────────────────────────────────
|
|
504
|
-
|
|
505
|
-
/**
|
|
506
|
-
* Called from the template when the user presses the mouse button on a node.
|
|
507
|
-
* Starts the drag interaction and registers document-level listeners so the
|
|
508
|
-
* drag continues even when the cursor leaves the SVG canvas.
|
|
509
|
-
*/
|
|
510
|
-
onNodeMouseDown(event: MouseEvent, node: Node, swimlaneIndex: number): void {
|
|
511
|
-
// Do not interfere with connection dragging or open popups
|
|
512
|
-
if (
|
|
513
|
-
this.state.isConnectionDragging() ||
|
|
514
|
-
this.popupVisible ||
|
|
515
|
-
this.showStartNodeFormPopup ||
|
|
516
|
-
this.showSubflowPopup
|
|
517
|
-
) return;
|
|
518
|
-
|
|
519
|
-
event.stopPropagation(); // Prevent onCanvasClick from firing
|
|
520
|
-
event.preventDefault();
|
|
521
|
-
|
|
522
|
-
const position = this.getMousePosition(event);
|
|
523
|
-
// Template formula: absoluteSVGY = node.y + swimlane.order * 263
|
|
524
|
-
const absoluteNodeY = node.y + swimlaneIndex * this.swimlaneHeight;
|
|
525
|
-
|
|
526
|
-
this.isDraggingNode = true;
|
|
527
|
-
this.draggingNode = node;
|
|
528
|
-
this.draggingNodeSwimlaneIndex = swimlaneIndex;
|
|
529
|
-
// Store the offset from the node's top-left so the node doesn't jump
|
|
530
|
-
this.dragOffsetX = position.x - node.x;
|
|
531
|
-
this.dragOffsetY = position.y - absoluteNodeY;
|
|
532
|
-
|
|
533
|
-
// Seed pending values with the node's CURRENT position so that a plain
|
|
534
|
-
// click (no mousemove) leaves node.y unchanged in onNodeDragEnd.
|
|
535
|
-
this._pendingAbsoluteY = absoluteNodeY;
|
|
536
|
-
this._pendingTargetSwimlaneIndex = swimlaneIndex;
|
|
537
|
-
|
|
538
|
-
document.addEventListener('mousemove', this.onNodeDragMove);
|
|
539
|
-
document.addEventListener('mouseup', this.onNodeDragEnd);
|
|
540
|
-
}
|
|
541
|
-
|
|
542
|
-
/**
|
|
543
|
-
* Arrow function (preserves `this`) — runs on every mousemove while dragging
|
|
544
|
-
* a node. Updates node.x / node.y in-place so Angular's change detection
|
|
545
|
-
* picks it up and redraws the node and all connected paths automatically.
|
|
546
|
-
*/
|
|
547
|
-
onNodeDragMove = (event: MouseEvent): void => {
|
|
548
|
-
if (!this.isDraggingNode || !this.draggingNode) return;
|
|
549
|
-
|
|
550
|
-
const position = this.getMousePosition(event);
|
|
551
|
-
|
|
552
|
-
// Raw desired absolute position of the node top-left
|
|
553
|
-
const rawAbsoluteX = position.x - this.dragOffsetX;
|
|
554
|
-
const rawAbsoluteY = position.y - this.dragOffsetY;
|
|
555
|
-
|
|
556
|
-
// Determine which swimlane the node is being dragged into (by cursor Y)
|
|
557
|
-
let targetSwimlaneIndex = Math.floor(position.y / this.swimlaneHeight);
|
|
558
|
-
targetSwimlaneIndex = Math.max(
|
|
559
|
-
0,
|
|
560
|
-
Math.min(targetSwimlaneIndex, this.state.swimlanes.length - 1)
|
|
561
|
-
);
|
|
562
|
-
|
|
563
|
-
const swimlaneTopY = targetSwimlaneIndex * this.swimlaneHeight;
|
|
564
|
-
const swimlaneBottomY = swimlaneTopY + this.swimlaneHeight;
|
|
565
|
-
const padding = 5;
|
|
566
|
-
|
|
567
|
-
// X: keep node fully on canvas (no left/right boundary needed for swimlanes)
|
|
568
|
-
const newAbsoluteX = Math.max(padding, rawAbsoluteX);
|
|
569
|
-
|
|
570
|
-
// Y: clamp so the node stays inside the targeted swimlane
|
|
571
|
-
let newAbsoluteY = rawAbsoluteY;
|
|
572
|
-
const node = this.draggingNode;
|
|
573
|
-
if (newAbsoluteY < swimlaneTopY + padding) {
|
|
574
|
-
newAbsoluteY = swimlaneTopY + padding;
|
|
575
|
-
} else if (newAbsoluteY + node.height > swimlaneBottomY - padding) {
|
|
576
|
-
newAbsoluteY = swimlaneBottomY - node.height - padding;
|
|
577
|
-
}
|
|
578
|
-
|
|
579
|
-
// Convert absolute Y to swimlane-relative Y for storage
|
|
580
|
-
const newRelativeY = newAbsoluteY - targetSwimlaneIndex * this.swimlaneHeight;
|
|
581
|
-
|
|
582
|
-
// Live preview: update position directly.
|
|
583
|
-
// Template formula: absoluteSVGY = node.y + swimlane.order * 263
|
|
584
|
-
// => node.y = absoluteY - swimlane.order * 263 (swimlane-relative)
|
|
585
|
-
// The node is STILL in the source swimlane's array during preview,
|
|
586
|
-
// so swimlane.order = draggingNodeSwimlaneIndex.
|
|
587
|
-
node.x = newAbsoluteX;
|
|
588
|
-
node.y = newAbsoluteY - this.draggingNodeSwimlaneIndex * this.swimlaneHeight;
|
|
589
|
-
|
|
590
|
-
// Store computed values for onNodeDragEnd
|
|
591
|
-
this._pendingTargetSwimlaneIndex = targetSwimlaneIndex;
|
|
592
|
-
this._pendingAbsoluteY = newAbsoluteY;
|
|
593
|
-
};
|
|
594
|
-
|
|
595
|
-
/** Scratch fields used to pass computed values from move → end handlers. */
|
|
596
|
-
private _pendingTargetSwimlaneIndex = -1;
|
|
597
|
-
private _pendingAbsoluteY = 0;
|
|
598
|
-
|
|
599
|
-
/**
|
|
600
|
-
* Arrow function (preserves `this`) — fires on mouseup after a node drag.
|
|
601
|
-
* Finalises the node position and performs swimlane migration if necessary.
|
|
602
|
-
*/
|
|
603
|
-
onNodeDragEnd = (_event: MouseEvent): void => {
|
|
604
|
-
document.removeEventListener('mousemove', this.onNodeDragMove);
|
|
605
|
-
document.removeEventListener('mouseup', this.onNodeDragEnd);
|
|
606
|
-
|
|
607
|
-
if (!this.isDraggingNode || !this.draggingNode) {
|
|
608
|
-
this.isDraggingNode = false;
|
|
609
|
-
this.draggingNode = null;
|
|
610
|
-
return;
|
|
611
|
-
}
|
|
612
|
-
|
|
613
|
-
const node = this.draggingNode;
|
|
614
|
-
const fromIndex = this.draggingNodeSwimlaneIndex;
|
|
615
|
-
const toIndex = this._pendingTargetSwimlaneIndex !== -1
|
|
616
|
-
? this._pendingTargetSwimlaneIndex
|
|
617
|
-
: fromIndex;
|
|
618
|
-
const absoluteY = this._pendingAbsoluteY;
|
|
619
|
-
|
|
620
|
-
if (fromIndex !== toIndex) {
|
|
621
|
-
// Cross-swimlane drop: state helper moves node between arrays,
|
|
622
|
-
// updates connections, and syncs tags. It also sets node.y correctly.
|
|
623
|
-
this.state.moveNodeToSwimlane(node.id, fromIndex, toIndex, node.x, absoluteY);
|
|
624
|
-
} else {
|
|
625
|
-
// Same swimlane: node.y = absoluteY - swimlane.order * 263 (swimlane-relative)
|
|
626
|
-
node.y = absoluteY - fromIndex * this.swimlaneHeight;
|
|
627
|
-
}
|
|
628
|
-
|
|
629
|
-
// Reset drag state
|
|
630
|
-
this.isDraggingNode = false;
|
|
631
|
-
this.draggingNode = null;
|
|
632
|
-
this.draggingNodeSwimlaneIndex = -1;
|
|
633
|
-
this.dragOffsetX = 0;
|
|
634
|
-
this.dragOffsetY = 0;
|
|
635
|
-
this._pendingTargetSwimlaneIndex = -1;
|
|
636
|
-
this._pendingAbsoluteY = 0;
|
|
637
|
-
};
|
|
638
|
-
|
|
639
|
-
/**
|
|
640
|
-
* Returns a CSS cursor value for the node rendering.
|
|
641
|
-
* Shows 'grabbing' while the node is being dragged, 'grab' otherwise.
|
|
642
|
-
*/
|
|
643
|
-
getCursorForNode(nodeId: string): string {
|
|
644
|
-
return this.isDraggingNode && this.draggingNode?.id === nodeId ? 'grabbing' : 'grab';
|
|
645
|
-
}
|
|
646
|
-
|
|
647
|
-
// ─────────────────────────────────────────────────────────────────────────
|
|
648
|
-
// Connection drag logic (existing)
|
|
649
|
-
// ─────────────────────────────────────────────────────────────────────────
|
|
650
|
-
|
|
651
|
-
// Use arrow functions to preserve 'this' context
|
|
652
|
-
onMouseMove = (event: MouseEvent) => {
|
|
653
|
-
const position = this.getMousePosition(event);
|
|
654
|
-
this.updateConnectionDrag(position.x, position.y);
|
|
655
|
-
this.highlightPotentialTargets(event);
|
|
656
|
-
};
|
|
657
|
-
|
|
658
|
-
updateConnectionDrag(currentX: number, currentY: number) {
|
|
659
|
-
if (this.state.draggingConnectionData.sourcePoint) {
|
|
660
|
-
this.state.draggingConnectionData.currentX = currentX;
|
|
661
|
-
this.state.draggingConnectionData.currentY = currentY;
|
|
662
|
-
|
|
663
|
-
// Calculate which swimlane the cursor is over
|
|
664
|
-
const swimlaneIndex = Math.floor(currentY / this.swimlaneHeight);
|
|
665
|
-
if (swimlaneIndex >= 0 && swimlaneIndex < this.state.swimlanes.length) {
|
|
666
|
-
// Ensure the target swimlane is fully visible
|
|
667
|
-
this.ensureSwimlaneInView(swimlaneIndex);
|
|
668
|
-
}
|
|
669
|
-
}
|
|
670
|
-
}
|
|
671
|
-
|
|
672
|
-
/**
|
|
673
|
-
* Terminates a connection drag. Three outcomes, evaluated in order:
|
|
674
|
-
*
|
|
675
|
-
* 1. **Dropped on an existing connection point** — if the source and target
|
|
676
|
-
* are different nodes and `state.canConnect` allows the type pairing, the
|
|
677
|
-
* connection is created immediately.
|
|
678
|
-
* 2. **Dropped inside a swimlane but not on a point** — opens the node-type
|
|
679
|
-
* popup ({@link showConnectionPopup}), offering only the types permitted by
|
|
680
|
-
* `state.getAllowedTargetNodeTypes()`. The node is created later, by
|
|
681
|
-
* {@link createNodeConnection}.
|
|
682
|
-
* 3. **Dropped outside every swimlane** — the drag is cancelled.
|
|
683
|
-
*
|
|
684
|
-
* Always detaches the document-level move/up listeners first, so an early
|
|
685
|
-
* return cannot leave them attached.
|
|
686
|
-
*/
|
|
687
|
-
onMouseUp = (event: MouseEvent) => {
|
|
688
|
-
document.removeEventListener('mousemove', this.onMouseMove);
|
|
689
|
-
document.removeEventListener('mouseup', this.onMouseUp);
|
|
690
|
-
|
|
691
|
-
const position = this.getMousePosition(event);
|
|
692
|
-
|
|
693
|
-
// Only proceed if we are dragging a connection
|
|
694
|
-
if (!this.state.isConnectionDragging()) {
|
|
695
|
-
return;
|
|
696
|
-
}
|
|
697
|
-
|
|
698
|
-
// Check if we're dropping onto a connection point
|
|
699
|
-
const targetPointInfo = this.findConnectionPointAtPosition(
|
|
700
|
-
position.x,
|
|
701
|
-
position.y
|
|
702
|
-
);
|
|
703
|
-
|
|
704
|
-
if (targetPointInfo) {
|
|
705
|
-
// We found a target connection point
|
|
706
|
-
|
|
707
|
-
// Get the source point and swimlane index
|
|
708
|
-
const sourcePoint = this.state.draggingConnectionData.sourcePoint;
|
|
709
|
-
const sourceSwimlaneIndex =
|
|
710
|
-
this.state.draggingConnectionData.sourceSwimlaneIndex;
|
|
711
|
-
|
|
712
|
-
if (sourcePoint && sourceSwimlaneIndex !== undefined) {
|
|
713
|
-
// Prevent connecting a node to itself
|
|
714
|
-
if (sourcePoint.nodeId !== targetPointInfo.nodeId) {
|
|
715
|
-
// Get source and target node types to check if connection is allowed
|
|
716
|
-
const sourceNodeInfo = this.state.findNodeById(sourcePoint.nodeId);
|
|
717
|
-
const targetNodeInfo = this.state.findNodeById(
|
|
718
|
-
targetPointInfo.nodeId
|
|
719
|
-
);
|
|
720
|
-
|
|
721
|
-
if (
|
|
722
|
-
sourceNodeInfo &&
|
|
723
|
-
targetNodeInfo &&
|
|
724
|
-
this.state.canConnect(
|
|
725
|
-
sourceNodeInfo.node.type,
|
|
726
|
-
targetNodeInfo.node.type
|
|
727
|
-
)
|
|
728
|
-
) {
|
|
729
|
-
// Create the connection
|
|
730
|
-
const connection = {
|
|
731
|
-
id: `conn-${Date.now()}-${Math.floor(Math.random() * 1000)}`,
|
|
732
|
-
sourceNodeId: sourcePoint.nodeId,
|
|
733
|
-
targetNodeId: targetPointInfo.nodeId,
|
|
734
|
-
sourcePointId: sourcePoint.id,
|
|
735
|
-
targetPointId: targetPointInfo.point.id,
|
|
736
|
-
sourceSwimlaneIndex: sourceSwimlaneIndex,
|
|
737
|
-
targetSwimlaneIndex: targetPointInfo.swimlaneIndex,
|
|
738
|
-
label: '',
|
|
739
|
-
action: null,
|
|
740
|
-
};
|
|
741
|
-
|
|
742
|
-
// Add to connections array
|
|
743
|
-
this.state.connections.push(connection);
|
|
744
|
-
|
|
745
|
-
// Notify about connection creation
|
|
746
|
-
this.onConnectionCreated(connection);
|
|
747
|
-
}
|
|
748
|
-
}
|
|
749
|
-
}
|
|
750
|
-
|
|
751
|
-
// End the connection drag
|
|
752
|
-
this.state.endConnectionDrag();
|
|
753
|
-
return;
|
|
754
|
-
}
|
|
755
|
-
|
|
756
|
-
// Check if the position is within any swimlane
|
|
757
|
-
const isInsideSwimlane = this.isPositionInsideSwimlane(position.y);
|
|
758
|
-
|
|
759
|
-
// Only show popup if within a swimlane
|
|
760
|
-
if (isInsideSwimlane && this.state.isConnectionDragging()) {
|
|
761
|
-
this.showConnectionPopup(position.x, position.y);
|
|
762
|
-
} else {
|
|
763
|
-
// End the connection drag if outside a swimlane
|
|
764
|
-
this.state.endConnectionDrag();
|
|
765
|
-
}
|
|
766
|
-
};
|
|
767
|
-
|
|
768
|
-
/**
|
|
769
|
-
* Hit-tests an absolute canvas position against every node's connection
|
|
770
|
-
* points, resolving each to absolute space as
|
|
771
|
-
* `node.y + swimlaneIndex * 263 + point.y` — the inverse of the render
|
|
772
|
-
* formula.
|
|
773
|
-
*
|
|
774
|
-
* Returns the first point within `tolerance` pixels, or `null`. Scans all
|
|
775
|
-
* lanes and all nodes linearly.
|
|
776
|
-
*
|
|
777
|
-
* @param x Absolute canvas X (from {@link getMousePosition}).
|
|
778
|
-
* @param y Absolute canvas Y.
|
|
779
|
-
* @param tolerance Hit radius in pixels.
|
|
780
|
-
*/
|
|
781
|
-
findConnectionPointAtPosition(
|
|
782
|
-
x: number,
|
|
783
|
-
y: number,
|
|
784
|
-
tolerance: number = 10
|
|
785
|
-
): {
|
|
786
|
-
point: ConnectionPoint;
|
|
787
|
-
nodeId: string;
|
|
788
|
-
swimlaneIndex: number;
|
|
789
|
-
} | null {
|
|
790
|
-
// Iterate through all swimlanes and nodes to find connection points
|
|
791
|
-
for (
|
|
792
|
-
let swimlaneIndex = 0;
|
|
793
|
-
swimlaneIndex < this.state.swimlanes.length;
|
|
794
|
-
swimlaneIndex++
|
|
795
|
-
) {
|
|
796
|
-
const swimlane = this.state.swimlanes[swimlaneIndex];
|
|
797
|
-
|
|
798
|
-
if (!swimlane.nodes) continue;
|
|
799
|
-
|
|
800
|
-
for (const node of swimlane.nodes) {
|
|
801
|
-
if (!node.connectionPoints) continue;
|
|
802
|
-
|
|
803
|
-
// Calculate the absolute position of the node (including swimlane offset)
|
|
804
|
-
const absoluteNodeX = node.x;
|
|
805
|
-
const absoluteNodeY = node.y + swimlaneIndex * this.swimlaneHeight;
|
|
806
|
-
|
|
807
|
-
for (const point of node.connectionPoints) {
|
|
808
|
-
// Calculate absolute position of the connection point
|
|
809
|
-
const pointX = absoluteNodeX + point.x;
|
|
810
|
-
const pointY = absoluteNodeY + point.y;
|
|
811
|
-
|
|
812
|
-
// Check if the given position is within tolerance of this point
|
|
813
|
-
if (
|
|
814
|
-
Math.abs(x - pointX) <= tolerance &&
|
|
815
|
-
Math.abs(y - pointY) <= tolerance
|
|
816
|
-
) {
|
|
817
|
-
return {
|
|
818
|
-
point: point,
|
|
819
|
-
nodeId: node.id,
|
|
820
|
-
swimlaneIndex: swimlaneIndex,
|
|
821
|
-
};
|
|
822
|
-
}
|
|
823
|
-
}
|
|
824
|
-
}
|
|
825
|
-
}
|
|
826
|
-
|
|
827
|
-
return null;
|
|
828
|
-
}
|
|
829
|
-
|
|
830
|
-
isPositionInsideSwimlane(y: number): boolean {
|
|
831
|
-
// Check if y position is within any swimlane
|
|
832
|
-
const swimlaneCount = this.state.swimlanes.length;
|
|
833
|
-
if (swimlaneCount === 0) return false;
|
|
834
|
-
|
|
835
|
-
// Each swimlane has a height of 263px
|
|
836
|
-
const totalSwimlaneHeight = swimlaneCount * this.swimlaneHeight;
|
|
837
|
-
|
|
838
|
-
// Check if y is within the total height of all swimlanes
|
|
839
|
-
return y >= 0 && y < totalSwimlaneHeight;
|
|
840
|
-
}
|
|
841
|
-
|
|
842
|
-
showConnectionPopup(x: number, y: number): void {
|
|
843
|
-
|
|
844
|
-
// Convert canvas coordinates to viewport coordinates for popup positioning
|
|
845
|
-
const viewportPos = this.getViewportPosition(x, y);
|
|
846
|
-
this.popupX = viewportPos.x;
|
|
847
|
-
this.popupY = viewportPos.y;
|
|
848
|
-
|
|
849
|
-
// Get allowed node types based on the source node type
|
|
850
|
-
this.allowedNodeTypes = this.state.getAllowedTargetNodeTypes();
|
|
851
|
-
|
|
852
|
-
// Only show the popup if we have allowed node types
|
|
853
|
-
if (this.allowedNodeTypes.length > 0) {
|
|
854
|
-
this.popupVisible = true;
|
|
855
|
-
|
|
856
|
-
// Force the popup to be visible in the next tick
|
|
857
|
-
} else {
|
|
858
|
-
// No allowed node types, just end the drag
|
|
859
|
-
this.state.endConnectionDrag();
|
|
860
|
-
}
|
|
861
|
-
}
|
|
862
|
-
|
|
863
|
-
hideConnectionPopup(): void {
|
|
864
|
-
this.popupVisible = false;
|
|
865
|
-
this.state.endConnectionDrag();
|
|
866
|
-
}
|
|
867
|
-
|
|
868
|
-
// Add this handler to close the popup when clicking outside
|
|
869
|
-
// @HostListener('document:click', ['$event'])
|
|
870
|
-
// onDocumentClick(event: MouseEvent): void {
|
|
871
|
-
// if (this.popupVisible) {
|
|
872
|
-
// const popupElement = document.querySelector('verben-pop-Up');
|
|
873
|
-
// if (popupElement && !popupElement.contains(event.target as Node)) {
|
|
874
|
-
// this.hideConnectionPopup();
|
|
875
|
-
// }
|
|
876
|
-
// }
|
|
877
|
-
// }
|
|
878
|
-
|
|
879
|
-
/**
|
|
880
|
-
* Creates a new node at the drop point and connects the dragged edge to it —
|
|
881
|
-
* the path taken when the user picks a type from the node-type popup.
|
|
882
|
-
*
|
|
883
|
-
* ## The coordinate contract this method must honour
|
|
884
|
-
*
|
|
885
|
-
* The target swimlane is derived from the **drop** Y
|
|
886
|
-
* (`Math.floor(endY / 263)`, clamped to the lane range), and `endY` is passed
|
|
887
|
-
* to `state.addNode` **absolute and unconverted**. `addNode` performs the
|
|
888
|
-
* lane-relative conversion itself.
|
|
889
|
-
*
|
|
890
|
-
* This method previously did the opposite — pre-converting `endY` and passing
|
|
891
|
-
* the *source* lane — which made `addNode` subtract the lane offset twice, so
|
|
892
|
-
* the new stage rendered one lane too high and attached to the wrong
|
|
893
|
-
* swimlane. `designer-canvas.connection-drop.spec.ts` guards against the
|
|
894
|
-
* regression. Do not reintroduce a conversion here.
|
|
895
|
-
*
|
|
896
|
-
* Connecting a decision to a stage defers node creation until the branch
|
|
897
|
-
* condition is supplied, via {@link pendingDecisionConnection}.
|
|
898
|
-
*/
|
|
899
|
-
createNodeConnection(nodeType: string): void {
|
|
900
|
-
const pathData = this.state.getConnectionPathData();
|
|
901
|
-
if (!pathData) {
|
|
902
|
-
this.hideConnectionPopup();
|
|
903
|
-
return;
|
|
904
|
-
}
|
|
905
|
-
|
|
906
|
-
// Check if this node type is allowed to be created
|
|
907
|
-
const allowedTypes = this.state.getAllowedTargetNodeTypes();
|
|
908
|
-
if (!allowedTypes.includes(nodeType)) {
|
|
909
|
-
this.hideConnectionPopup();
|
|
910
|
-
return;
|
|
911
|
-
}
|
|
912
|
-
|
|
913
|
-
const { endX, endY } = pathData;
|
|
914
|
-
|
|
915
|
-
// Determine the target swimlane from the drop position (NOT the source
|
|
916
|
-
// swimlane). `addNode` expects an absolute canvas Y plus the target
|
|
917
|
-
// swimlane index, and performs the swimlane-relative conversion itself.
|
|
918
|
-
let targetSwimlaneIndex = Math.floor(endY / this.swimlaneHeight);
|
|
919
|
-
targetSwimlaneIndex = Math.max(
|
|
920
|
-
0,
|
|
921
|
-
Math.min(targetSwimlaneIndex, this.state.swimlanes.length - 1)
|
|
922
|
-
);
|
|
923
|
-
|
|
924
|
-
// Get source node info
|
|
925
|
-
const sourcePoint = this.state.draggingConnectionData.sourcePoint;
|
|
926
|
-
if (!sourcePoint) {
|
|
927
|
-
this.hideConnectionPopup();
|
|
928
|
-
return;
|
|
929
|
-
}
|
|
930
|
-
|
|
931
|
-
const sourceNodeInfo = this.state.findNodeById(sourcePoint.nodeId);
|
|
932
|
-
if (!sourceNodeInfo) {
|
|
933
|
-
this.hideConnectionPopup();
|
|
934
|
-
return;
|
|
935
|
-
}
|
|
936
|
-
|
|
937
|
-
// If connecting from a decision to a stage, show condition popup first
|
|
938
|
-
if (sourceNodeInfo.node.type === 'decision' && nodeType === 'stage') {
|
|
939
|
-
// Store information for later stage creation
|
|
940
|
-
this.pendingDecisionConnection = {
|
|
941
|
-
decisionNodeId: sourceNodeInfo.node.id,
|
|
942
|
-
swimlaneIndex: targetSwimlaneIndex,
|
|
943
|
-
x: endX,
|
|
944
|
-
y: endY,
|
|
945
|
-
};
|
|
946
|
-
|
|
947
|
-
// Center the popup over the connection endpoint
|
|
948
|
-
this.decisionConditionPopupX = endX;
|
|
949
|
-
this.decisionConditionPopupY = endY - 150; // Position above the endpoint
|
|
950
|
-
|
|
951
|
-
// Set decision node ID
|
|
952
|
-
this.activeDecisionNodeId = sourceNodeInfo.node.id;
|
|
953
|
-
this.showDecisionConditionDialog = true;
|
|
954
|
-
|
|
955
|
-
// End the connection drag
|
|
956
|
-
this.hideConnectionPopup();
|
|
957
|
-
return;
|
|
958
|
-
}
|
|
959
|
-
|
|
960
|
-
// Handle preconditions based on node type
|
|
961
|
-
if (nodeType === 'stage') {
|
|
962
|
-
// Create the stage in the target swimlane. `addNode` converts the
|
|
963
|
-
// absolute endY to a swimlane-relative position internally.
|
|
964
|
-
const newNode = this.state.addNode(
|
|
965
|
-
targetSwimlaneIndex,
|
|
966
|
-
'stage',
|
|
967
|
-
endX,
|
|
968
|
-
endY,
|
|
969
|
-
{ Name: 'New Stage' } // Add default properties
|
|
970
|
-
);
|
|
971
|
-
|
|
972
|
-
if (
|
|
973
|
-
newNode &&
|
|
974
|
-
newNode.connectionPoints &&
|
|
975
|
-
newNode.connectionPoints.length > 0 &&
|
|
976
|
-
sourcePoint
|
|
977
|
-
) {
|
|
978
|
-
// Handle connection creation
|
|
979
|
-
const opposingType = {
|
|
980
|
-
right: 'left',
|
|
981
|
-
left: 'right',
|
|
982
|
-
top: 'bottom',
|
|
983
|
-
bottom: 'top',
|
|
984
|
-
}[sourcePoint.type] as 'top' | 'right' | 'bottom' | 'left';
|
|
985
|
-
|
|
986
|
-
const targetPoint = newNode.connectionPoints.find(
|
|
987
|
-
(p) => p.type === opposingType
|
|
988
|
-
);
|
|
989
|
-
|
|
990
|
-
if (targetPoint) {
|
|
991
|
-
// Create the connection
|
|
992
|
-
const connection = this.state.createConnection(
|
|
993
|
-
newNode.id,
|
|
994
|
-
targetPoint.id,
|
|
995
|
-
targetSwimlaneIndex
|
|
996
|
-
);
|
|
997
|
-
|
|
998
|
-
if (connection) {
|
|
999
|
-
this.onConnectionCreated(connection);
|
|
1000
|
-
}
|
|
1001
|
-
}
|
|
1002
|
-
}
|
|
1003
|
-
|
|
1004
|
-
this.hideConnectionPopup();
|
|
1005
|
-
return;
|
|
1006
|
-
} else if (nodeType === 'subflow') {
|
|
1007
|
-
// Show workflow selection popup and store connection data for later use
|
|
1008
|
-
this.showSubflowSelectionPopup(endX, endY, targetSwimlaneIndex);
|
|
1009
|
-
this.hideConnectionPopup();
|
|
1010
|
-
return;
|
|
1011
|
-
}
|
|
1012
|
-
|
|
1013
|
-
// For other nodes Create the new node at the end position of the connection
|
|
1014
|
-
const newNode = this.state.addNode(
|
|
1015
|
-
targetSwimlaneIndex,
|
|
1016
|
-
nodeType as ToolType,
|
|
1017
|
-
endX,
|
|
1018
|
-
endY
|
|
1019
|
-
);
|
|
1020
|
-
|
|
1021
|
-
if (
|
|
1022
|
-
newNode &&
|
|
1023
|
-
newNode.connectionPoints &&
|
|
1024
|
-
newNode.connectionPoints.length > 0
|
|
1025
|
-
) {
|
|
1026
|
-
// Find the most appropriate connection point (closest to the source)
|
|
1027
|
-
if (sourcePoint) {
|
|
1028
|
-
// For simplicity, use the first connection point of opposing type
|
|
1029
|
-
// In a real implementation, you'd find the closest or most appropriate point
|
|
1030
|
-
let targetPoint;
|
|
1031
|
-
|
|
1032
|
-
// If source is on right, target should be on left, etc.
|
|
1033
|
-
const opposingType = {
|
|
1034
|
-
right: 'left',
|
|
1035
|
-
left: 'right',
|
|
1036
|
-
top: 'bottom',
|
|
1037
|
-
bottom: 'top',
|
|
1038
|
-
}[sourcePoint.type] as 'top' | 'right' | 'bottom' | 'left';
|
|
1039
|
-
|
|
1040
|
-
targetPoint = newNode.connectionPoints.find(
|
|
1041
|
-
(p) => p.type === opposingType
|
|
1042
|
-
);
|
|
1043
|
-
|
|
1044
|
-
if (targetPoint) {
|
|
1045
|
-
// Create the connection
|
|
1046
|
-
const connection = this.state.createConnection(
|
|
1047
|
-
newNode.id,
|
|
1048
|
-
targetPoint.id,
|
|
1049
|
-
targetSwimlaneIndex
|
|
1050
|
-
);
|
|
1051
|
-
|
|
1052
|
-
if (connection) {
|
|
1053
|
-
this.onConnectionCreated(connection);
|
|
1054
|
-
}
|
|
1055
|
-
}
|
|
1056
|
-
}
|
|
1057
|
-
}
|
|
1058
|
-
|
|
1059
|
-
if (sourceNodeInfo) {
|
|
1060
|
-
this.updateNodeConnections(sourceNodeInfo.node);
|
|
1061
|
-
}
|
|
1062
|
-
|
|
1063
|
-
// End the connection drag
|
|
1064
|
-
this.hideConnectionPopup();
|
|
1065
|
-
}
|
|
1066
|
-
|
|
1067
|
-
// Method to handle saving the condition
|
|
1068
|
-
onDecisionConditionSaved(event: {
|
|
1069
|
-
connectionId: string;
|
|
1070
|
-
condition: string;
|
|
1071
|
-
}): void {
|
|
1072
|
-
if (!this.pendingDecisionConnection) {
|
|
1073
|
-
this.showDecisionConditionDialog = false;
|
|
1074
|
-
return;
|
|
1075
|
-
}
|
|
1076
|
-
|
|
1077
|
-
const { decisionNodeId, swimlaneIndex, x, y } =
|
|
1078
|
-
this.pendingDecisionConnection;
|
|
1079
|
-
|
|
1080
|
-
// Create the stage directly with default properties
|
|
1081
|
-
const node = this.state.addNode(
|
|
1082
|
-
swimlaneIndex,
|
|
1083
|
-
'stage',
|
|
1084
|
-
x,
|
|
1085
|
-
y,
|
|
1086
|
-
{ Name: 'New Stage' } // Add default properties
|
|
1087
|
-
);
|
|
1088
|
-
|
|
1089
|
-
if (node) {
|
|
1090
|
-
const decisionNodeInfo = this.state.findNodeById(decisionNodeId);
|
|
1091
|
-
|
|
1092
|
-
if (
|
|
1093
|
-
decisionNodeInfo &&
|
|
1094
|
-
node.connectionPoints &&
|
|
1095
|
-
node.connectionPoints.length > 0
|
|
1096
|
-
) {
|
|
1097
|
-
// Find a suitable connection point from the decision node
|
|
1098
|
-
const decisionNode = decisionNodeInfo.node;
|
|
1099
|
-
const decisionNodePoints = decisionNode.connectionPoints || [];
|
|
1100
|
-
const sourcePoint = decisionNodePoints.find(
|
|
1101
|
-
(p) => p.type === 'right' || p.type === 'bottom'
|
|
1102
|
-
);
|
|
1103
|
-
|
|
1104
|
-
if (sourcePoint) {
|
|
1105
|
-
// Find opposing type connection point on the new stage
|
|
1106
|
-
const opposingType = {
|
|
1107
|
-
right: 'left',
|
|
1108
|
-
bottom: 'top',
|
|
1109
|
-
left: 'right',
|
|
1110
|
-
top: 'bottom',
|
|
1111
|
-
}[sourcePoint.type] as 'top' | 'right' | 'bottom' | 'left';
|
|
1112
|
-
|
|
1113
|
-
const targetPoint = node.connectionPoints.find(
|
|
1114
|
-
(p) => p.type === opposingType
|
|
1115
|
-
);
|
|
1116
|
-
|
|
1117
|
-
if (targetPoint) {
|
|
1118
|
-
// Create connection with condition
|
|
1119
|
-
const connection = {
|
|
1120
|
-
id: `conn-${Date.now()}-${Math.floor(Math.random() * 1000)}`,
|
|
1121
|
-
sourceNodeId: decisionNode.id,
|
|
1122
|
-
targetNodeId: node.id,
|
|
1123
|
-
sourcePointId: sourcePoint.id,
|
|
1124
|
-
targetPointId: targetPoint.id,
|
|
1125
|
-
sourceSwimlaneIndex: decisionNodeInfo.swimlaneIndex,
|
|
1126
|
-
targetSwimlaneIndex: swimlaneIndex,
|
|
1127
|
-
condition: event.condition,
|
|
1128
|
-
label: '',
|
|
1129
|
-
action: null,
|
|
1130
|
-
};
|
|
1131
|
-
|
|
1132
|
-
// Add connection to the state
|
|
1133
|
-
this.state.connections.push(connection);
|
|
1134
|
-
}
|
|
1135
|
-
}
|
|
1136
|
-
}
|
|
1137
|
-
}
|
|
1138
|
-
|
|
1139
|
-
// Clear pending data
|
|
1140
|
-
this.pendingDecisionConnection = null;
|
|
1141
|
-
this.pendingDecisionCondition = '';
|
|
1142
|
-
|
|
1143
|
-
// Hide the condition popup
|
|
1144
|
-
this.showDecisionConditionDialog = false;
|
|
1145
|
-
}
|
|
1146
|
-
|
|
1147
|
-
onDecisionConditionCancelled(): void {
|
|
1148
|
-
this.showDecisionConditionDialog = false;
|
|
1149
|
-
// Don't create the stage or connection
|
|
1150
|
-
}
|
|
1151
|
-
|
|
1152
|
-
getConnectionPath(): string {
|
|
1153
|
-
const pathData = this.state.getConnectionPathData();
|
|
1154
|
-
if (!pathData) return '';
|
|
1155
|
-
|
|
1156
|
-
const { startX, startY, endX, endY } = pathData;
|
|
1157
|
-
const sourcePoint = this.state.draggingConnectionData.sourcePoint;
|
|
1158
|
-
|
|
1159
|
-
if (!sourcePoint) return '';
|
|
1160
|
-
|
|
1161
|
-
return this.getOrthogonalPath(startX, startY, endX, endY, sourcePoint.type);
|
|
1162
|
-
}
|
|
1163
|
-
|
|
1164
|
-
getConnectionPathForSavedConnection(connection: Connection): string {
|
|
1165
|
-
try {
|
|
1166
|
-
const pathData = this.state.getConnectionData(connection);
|
|
1167
|
-
if (!pathData) {
|
|
1168
|
-
return '';
|
|
1169
|
-
}
|
|
1170
|
-
|
|
1171
|
-
const { startX, startY, endX, endY } = pathData;
|
|
1172
|
-
|
|
1173
|
-
const sourceNodeInfo = this.state.findNodeById(connection.sourceNodeId);
|
|
1174
|
-
if (!sourceNodeInfo) {
|
|
1175
|
-
return '';
|
|
1176
|
-
}
|
|
1177
|
-
|
|
1178
|
-
const sourceNode = sourceNodeInfo.node;
|
|
1179
|
-
const sourcePoint = sourceNode.connectionPoints?.find(
|
|
1180
|
-
(p) => p.id === connection.sourcePointId
|
|
1181
|
-
);
|
|
1182
|
-
|
|
1183
|
-
if (!sourcePoint) {
|
|
1184
|
-
return '';
|
|
1185
|
-
}
|
|
1186
|
-
|
|
1187
|
-
return this.getOrthogonalPath(
|
|
1188
|
-
startX,
|
|
1189
|
-
startY,
|
|
1190
|
-
endX,
|
|
1191
|
-
endY,
|
|
1192
|
-
sourcePoint.type
|
|
1193
|
-
);
|
|
1194
|
-
} catch (error) {
|
|
1195
|
-
return '';
|
|
1196
|
-
}
|
|
1197
|
-
}
|
|
1198
|
-
|
|
1199
|
-
getOrthogonalPath(
|
|
1200
|
-
startX: number,
|
|
1201
|
-
startY: number,
|
|
1202
|
-
endX: number,
|
|
1203
|
-
endY: number,
|
|
1204
|
-
pointType: 'top' | 'right' | 'bottom' | 'left'
|
|
1205
|
-
): string {
|
|
1206
|
-
// Determine initial direction based on connection point type
|
|
1207
|
-
let path = '';
|
|
1208
|
-
|
|
1209
|
-
// For side points (left/right), start with horizontal line
|
|
1210
|
-
if (pointType === 'left' || pointType === 'right') {
|
|
1211
|
-
// Calculate horizontal distance
|
|
1212
|
-
const horizontalDist = endX - startX;
|
|
1213
|
-
|
|
1214
|
-
// If the end point is very close horizontally, use a simple 3-segment path
|
|
1215
|
-
if (Math.abs(horizontalDist) < 30) {
|
|
1216
|
-
const midY = (startY + endY) / 2;
|
|
1217
|
-
path = `M ${startX} ${startY} H ${endX} V ${midY} V ${endY}`;
|
|
1218
|
-
}
|
|
1219
|
-
// Otherwise, create a path with horizontal segment first, then vertical, then horizontal
|
|
1220
|
-
else {
|
|
1221
|
-
path = `M ${startX} ${startY} H ${startX + horizontalDist / 2
|
|
1222
|
-
} V ${endY} H ${endX}`;
|
|
1223
|
-
}
|
|
1224
|
-
}
|
|
1225
|
-
// For top/bottom points, start with vertical line
|
|
1226
|
-
else if (pointType === 'top' || pointType === 'bottom') {
|
|
1227
|
-
// Calculate vertical distance
|
|
1228
|
-
const verticalDist = endY - startY;
|
|
1229
|
-
|
|
1230
|
-
// If the end point is very close vertically, use a simple 3-segment path
|
|
1231
|
-
if (Math.abs(verticalDist) < 30) {
|
|
1232
|
-
const midX = (startX + endX) / 2;
|
|
1233
|
-
path = `M ${startX} ${startY} V ${endY} H ${midX} H ${endX}`;
|
|
1234
|
-
}
|
|
1235
|
-
// Otherwise, create a path with vertical segment first, then horizontal, then vertical
|
|
1236
|
-
else {
|
|
1237
|
-
path = `M ${startX} ${startY} V ${startY + verticalDist / 2
|
|
1238
|
-
} H ${endX} V ${endY}`;
|
|
1239
|
-
}
|
|
1240
|
-
}
|
|
1241
|
-
|
|
1242
|
-
return path;
|
|
1243
|
-
}
|
|
1244
|
-
|
|
1245
|
-
selectFormForStage(form: Form | null, node: Node) {
|
|
1246
|
-
// If form is null, we're clearing the selection
|
|
1247
|
-
if (node) {
|
|
1248
|
-
if (!node.stageData) {
|
|
1249
|
-
node.stageData = {};
|
|
1250
|
-
}
|
|
1251
|
-
|
|
1252
|
-
if (form) {
|
|
1253
|
-
node.stageData.formId = form.Code;
|
|
1254
|
-
node.stageData.formName = form.Name;
|
|
1255
|
-
} else {
|
|
1256
|
-
// Clear form selection
|
|
1257
|
-
delete node.stageData.formId;
|
|
1258
|
-
delete node.stageData.formName;
|
|
1259
|
-
}
|
|
1260
|
-
|
|
1261
|
-
// Emit an event to update the stage data
|
|
1262
|
-
this.onStagePropertiesUpdated({
|
|
1263
|
-
nodeId: node.id,
|
|
1264
|
-
stageData: node.stageData,
|
|
1265
|
-
});
|
|
1266
|
-
}
|
|
1267
|
-
}
|
|
1268
|
-
|
|
1269
|
-
onStagePropertiesUpdated(event: {
|
|
1270
|
-
nodeId: string;
|
|
1271
|
-
stageData: Partial<WorkflowStage>;
|
|
1272
|
-
}): void {
|
|
1273
|
-
// Find the node in the swimlanes
|
|
1274
|
-
for (let i = 0; i < this.state.swimlanes.length; i++) {
|
|
1275
|
-
const swimlane = this.state.swimlanes[i];
|
|
1276
|
-
const nodeIndex = swimlane.nodes?.findIndex((n) => n.id === event.nodeId);
|
|
1277
|
-
|
|
1278
|
-
if (nodeIndex !== undefined && nodeIndex >= 0) {
|
|
1279
|
-
// Update the stage data
|
|
1280
|
-
if (swimlane.nodes) {
|
|
1281
|
-
swimlane.nodes[nodeIndex].stageData = {
|
|
1282
|
-
...swimlane.nodes[nodeIndex].stageData,
|
|
1283
|
-
...event.stageData,
|
|
1284
|
-
};
|
|
1285
|
-
}
|
|
1286
|
-
break;
|
|
1287
|
-
}
|
|
1288
|
-
}
|
|
1289
|
-
}
|
|
1290
|
-
|
|
1291
|
-
onConnectionCreated(connection: Connection): void {
|
|
1292
|
-
// After a connection is created, refresh the source node to update its state
|
|
1293
|
-
const sourceNodeInfo = this.state.findNodeById(connection.sourceNodeId);
|
|
1294
|
-
if (sourceNodeInfo && sourceNodeInfo.node.type === 'stage') {
|
|
1295
|
-
// Refresh node state
|
|
1296
|
-
this.updateNodeConnections(sourceNodeInfo.node);
|
|
1297
|
-
}
|
|
1298
|
-
}
|
|
1299
|
-
|
|
1300
|
-
// Helper method to update node's connection status
|
|
1301
|
-
updateNodeConnections(node: WFNode): void {
|
|
1302
|
-
// Count the number of outgoing connections that connect to stages
|
|
1303
|
-
const outgoingConnections = this.state.connections.filter(
|
|
1304
|
-
(conn) => conn.sourceNodeId === node.id
|
|
1305
|
-
);
|
|
1306
|
-
|
|
1307
|
-
// Check if the target nodes are stages
|
|
1308
|
-
const connectedStageNodes = outgoingConnections
|
|
1309
|
-
.map((conn) => this.state.findNodeById(conn.targetNodeId))
|
|
1310
|
-
.filter((nodeInfo) => nodeInfo && nodeInfo.node.type === 'stage');
|
|
1311
|
-
|
|
1312
|
-
node.hasMultipleConnectedStages = connectedStageNodes.length > 1;
|
|
1313
|
-
node.hasParallelStages = connectedStageNodes.every(
|
|
1314
|
-
(nd) => nd?.node.stageData?.IsParallel
|
|
1315
|
-
);
|
|
1316
|
-
}
|
|
1317
|
-
|
|
1318
|
-
onEditSwimlane(
|
|
1319
|
-
event: MouseEvent,
|
|
1320
|
-
swimlane: SwimlaneItem,
|
|
1321
|
-
swimlaneIndex: number
|
|
1322
|
-
): void {
|
|
1323
|
-
event.stopPropagation(); // Prevent the canvas click event from firing
|
|
1324
|
-
event.preventDefault();
|
|
1325
|
-
|
|
1326
|
-
// Emit a special event for editing a swimlane
|
|
1327
|
-
this.clickedPosition.emit({
|
|
1328
|
-
x: -1, // Special value to indicate edit mode
|
|
1329
|
-
y: swimlaneIndex,
|
|
1330
|
-
});
|
|
1331
|
-
}
|
|
1332
|
-
|
|
1333
|
-
// showStartNodeFormPopup(event: MouseEvent): void {
|
|
1334
|
-
// event.preventDefault();
|
|
1335
|
-
// event.stopPropagation();
|
|
1336
|
-
|
|
1337
|
-
// // Implementation will be similar to the stage form popup
|
|
1338
|
-
// // We'll need to add UI elements for this
|
|
1339
|
-
// console.log('Start node form popup requested');
|
|
1340
|
-
|
|
1341
|
-
// // For now, this is a placeholder
|
|
1342
|
-
// // The actual implementation would load forms and add them to the workflow
|
|
1343
|
-
// }
|
|
1344
|
-
|
|
1345
|
-
toggleStartNodeFormPopup(
|
|
1346
|
-
event: MouseEvent,
|
|
1347
|
-
nodeX: number,
|
|
1348
|
-
nodeY: number,
|
|
1349
|
-
swimlaneIndex: number,
|
|
1350
|
-
node?: Node
|
|
1351
|
-
): void {
|
|
1352
|
-
event.preventDefault();
|
|
1353
|
-
event.stopPropagation();
|
|
1354
|
-
|
|
1355
|
-
// Set popup position - convert canvas coordinates to viewport coordinates
|
|
1356
|
-
const swimlaneOffset = swimlaneIndex * 263;
|
|
1357
|
-
const canvasX = nodeX - (!node ? 30 : 0);
|
|
1358
|
-
const canvasY = nodeY + swimlaneOffset;
|
|
1359
|
-
|
|
1360
|
-
const viewportPos = this.getViewportPosition(canvasX, canvasY);
|
|
1361
|
-
this.startNodeFormPopupX = viewportPos.x;
|
|
1362
|
-
this.startNodeFormPopupY = viewportPos.y;
|
|
1363
|
-
|
|
1364
|
-
// If we're opening the popup, load forms
|
|
1365
|
-
if (!this.showStartNodeFormPopup) {
|
|
1366
|
-
this.isLoadingStartNodeForms = true;
|
|
1367
|
-
this.dataService
|
|
1368
|
-
.getForms()
|
|
1369
|
-
.then((response) => {
|
|
1370
|
-
this.startNodeFormsList = response.Result;
|
|
1371
|
-
this.isLoadingStartNodeForms = false;
|
|
1372
|
-
})
|
|
1373
|
-
.catch((error) => {
|
|
1374
|
-
this.isLoadingStartNodeForms = false;
|
|
1375
|
-
});
|
|
1376
|
-
}
|
|
1377
|
-
|
|
1378
|
-
if (node) {
|
|
1379
|
-
this.activeNodeForFormSelection = node;
|
|
1380
|
-
} else {
|
|
1381
|
-
this.activeNodeForFormSelection = null;
|
|
1382
|
-
}
|
|
1383
|
-
|
|
1384
|
-
this.showStartNodeFormPopup = !this.showStartNodeFormPopup;
|
|
1385
|
-
}
|
|
1386
|
-
|
|
1387
|
-
selectStartNodeForm(form: Form | null): void {
|
|
1388
|
-
if (this.activeNodeForFormSelection) {
|
|
1389
|
-
this.selectFormForStage(form, this.activeNodeForFormSelection);
|
|
1390
|
-
} else {
|
|
1391
|
-
if (form) {
|
|
1392
|
-
this.state.setWorkflowForm(form.Code, form.Name);
|
|
1393
|
-
} else {
|
|
1394
|
-
this.state.setWorkflowForm(null, null);
|
|
1395
|
-
}
|
|
1396
|
-
}
|
|
1397
|
-
|
|
1398
|
-
// Close the popup
|
|
1399
|
-
this.showStartNodeFormPopup = false;
|
|
1400
|
-
}
|
|
1401
|
-
|
|
1402
|
-
showSubflowSelectionPopup(x: number, y: number, swimlaneIndex: number): void {
|
|
1403
|
-
// Convert canvas coordinates to viewport coordinates for popup positioning
|
|
1404
|
-
const viewportPos = this.getViewportPosition(x, y);
|
|
1405
|
-
this.subflowPopupX = viewportPos.x;
|
|
1406
|
-
this.subflowPopupY = viewportPos.y;
|
|
1407
|
-
this.pendingSubflowPosition = { swimlaneIndex, x, y };
|
|
1408
|
-
|
|
1409
|
-
// Store connection data if we're creating from a connection
|
|
1410
|
-
if (this.state.isConnectionDragging()) {
|
|
1411
|
-
// Store the source connection data
|
|
1412
|
-
this.pendingConnectionSourcePoint =
|
|
1413
|
-
this.state.draggingConnectionData.sourcePoint ?? null;
|
|
1414
|
-
this.pendingConnectionSourceSwimlaneIndex =
|
|
1415
|
-
this.state.draggingConnectionData.sourceSwimlaneIndex ?? null;
|
|
1416
|
-
}
|
|
1417
|
-
|
|
1418
|
-
// Load workflows
|
|
1419
|
-
this.isLoadingWorkflows = true;
|
|
1420
|
-
this.dataService
|
|
1421
|
-
.getWorkflows()
|
|
1422
|
-
.then((response) => {
|
|
1423
|
-
this.workflowsList = response.Result;
|
|
1424
|
-
this.isLoadingWorkflows = false;
|
|
1425
|
-
})
|
|
1426
|
-
.catch((error) => {
|
|
1427
|
-
this.isLoadingWorkflows = false;
|
|
1428
|
-
});
|
|
1429
|
-
|
|
1430
|
-
this.showSubflowPopup = true;
|
|
1431
|
-
}
|
|
1432
|
-
|
|
1433
|
-
selectSubflowWorkflow(workflow: Workflow): void {
|
|
1434
|
-
|
|
1435
|
-
if (this.pendingSubflowPosition) {
|
|
1436
|
-
const { swimlaneIndex, x, y } = this.pendingSubflowPosition;
|
|
1437
|
-
|
|
1438
|
-
// Create the subflow node with the selected workflow data
|
|
1439
|
-
const node = this.state.addNode(
|
|
1440
|
-
swimlaneIndex,
|
|
1441
|
-
'subflow',
|
|
1442
|
-
x,
|
|
1443
|
-
y,
|
|
1444
|
-
{ Name: workflow.Name }, // Initialize stage name from workflow
|
|
1445
|
-
{ id: workflow.Code, name: workflow.Name }
|
|
1446
|
-
);
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
// If this was created from a connection, create the connection
|
|
1450
|
-
if (node && this.pendingConnectionSourcePoint) {
|
|
1451
|
-
|
|
1452
|
-
// Find a suitable connection point on the new node
|
|
1453
|
-
if (node.connectionPoints && node.connectionPoints.length > 0) {
|
|
1454
|
-
const sourcePoint = this.pendingConnectionSourcePoint;
|
|
1455
|
-
|
|
1456
|
-
// Find opposing type connection point
|
|
1457
|
-
const opposingType = {
|
|
1458
|
-
right: 'left',
|
|
1459
|
-
left: 'right',
|
|
1460
|
-
top: 'bottom',
|
|
1461
|
-
bottom: 'top',
|
|
1462
|
-
}[sourcePoint.type] as 'top' | 'right' | 'bottom' | 'left';
|
|
1463
|
-
|
|
1464
|
-
const targetPoint = node.connectionPoints.find(
|
|
1465
|
-
(p) => p.type === opposingType
|
|
1466
|
-
);
|
|
1467
|
-
|
|
1468
|
-
if (targetPoint) {
|
|
1469
|
-
// Create connection
|
|
1470
|
-
const connection = {
|
|
1471
|
-
id: `conn-${Date.now()}-${Math.floor(Math.random() * 1000)}`,
|
|
1472
|
-
sourceNodeId: sourcePoint.nodeId,
|
|
1473
|
-
targetNodeId: node.id,
|
|
1474
|
-
sourcePointId: sourcePoint.id,
|
|
1475
|
-
targetPointId: targetPoint.id,
|
|
1476
|
-
sourceSwimlaneIndex: this.pendingConnectionSourceSwimlaneIndex!,
|
|
1477
|
-
targetSwimlaneIndex: swimlaneIndex,
|
|
1478
|
-
label: '',
|
|
1479
|
-
action: null,
|
|
1480
|
-
};
|
|
1481
|
-
|
|
1482
|
-
// Add connection directly to the state's connections array
|
|
1483
|
-
this.state.connections.push(connection);
|
|
1484
|
-
this.onConnectionCreated(connection);
|
|
1485
|
-
}
|
|
1486
|
-
}
|
|
1487
|
-
this.state.endConnectionDrag();
|
|
1488
|
-
}
|
|
1489
|
-
|
|
1490
|
-
// Reset selection tool in parent component
|
|
1491
|
-
this.subflowSelected.emit();
|
|
1492
|
-
}
|
|
1493
|
-
|
|
1494
|
-
// Clean up
|
|
1495
|
-
this.showSubflowPopup = false;
|
|
1496
|
-
this.pendingSubflowPosition = null;
|
|
1497
|
-
this.pendingConnectionSourcePoint = null;
|
|
1498
|
-
this.pendingConnectionSourceSwimlaneIndex = null;
|
|
1499
|
-
}
|
|
1500
|
-
|
|
1501
|
-
showDecisionConditionsPopup(
|
|
1502
|
-
event: MouseEvent,
|
|
1503
|
-
node: WFNode,
|
|
1504
|
-
swimlaneIndex: number
|
|
1505
|
-
): void {
|
|
1506
|
-
event.preventDefault();
|
|
1507
|
-
event.stopPropagation();
|
|
1508
|
-
|
|
1509
|
-
// Get the position for the popup
|
|
1510
|
-
const position = this.getMousePosition(event);
|
|
1511
|
-
|
|
1512
|
-
// Convert canvas coordinates to viewport coordinates for popup positioning
|
|
1513
|
-
const viewportPos = this.getViewportPosition(position.x, position.y);
|
|
1514
|
-
|
|
1515
|
-
// Find all connections from this decision node
|
|
1516
|
-
const connections = this.state.connections.filter(
|
|
1517
|
-
(conn) => conn.sourceNodeId === node.id
|
|
1518
|
-
);
|
|
1519
|
-
|
|
1520
|
-
if (connections.length === 0) {
|
|
1521
|
-
// No connections to show
|
|
1522
|
-
return;
|
|
1523
|
-
}
|
|
1524
|
-
|
|
1525
|
-
// Show the decision conditions popup
|
|
1526
|
-
this.activeDecisionNodeId = node.id;
|
|
1527
|
-
this.decisionConditionPopupX = viewportPos.x;
|
|
1528
|
-
this.decisionConditionPopupY = viewportPos.y;
|
|
1529
|
-
|
|
1530
|
-
// Set the correct popup visibility flag - this is likely the issue
|
|
1531
|
-
this.showDecisionConditionDialog = true;
|
|
1532
|
-
|
|
1533
|
-
// console.log('Showing decision popup:', {
|
|
1534
|
-
// y: globalY,
|
|
1535
|
-
// nodeId: node.id,
|
|
1536
|
-
// isVisible: this.showDecisionConditionDialog,
|
|
1537
|
-
// });
|
|
1538
|
-
}
|
|
1539
|
-
|
|
1540
|
-
ensureSwimlaneInView(swimlaneIndex: number): void {
|
|
1541
|
-
// Ensure we have enough swimlanes visible
|
|
1542
|
-
const requiredHeight = (swimlaneIndex + 1) * this.swimlaneHeight;
|
|
1543
|
-
if (this.canvasHeight < requiredHeight) {
|
|
1544
|
-
this.canvasHeight = requiredHeight;
|
|
1545
|
-
}
|
|
1546
|
-
}
|
|
1547
|
-
|
|
1548
|
-
getLabelPosition(connection: Connection): { x: number; y: number } {
|
|
1549
|
-
try {
|
|
1550
|
-
const pathData = this.state.getConnectionData(connection);
|
|
1551
|
-
if (!pathData) {
|
|
1552
|
-
return { x: 0, y: 0 };
|
|
1553
|
-
}
|
|
1554
|
-
|
|
1555
|
-
const { startX, startY, endX, endY } = pathData;
|
|
1556
|
-
|
|
1557
|
-
const sourceNodeInfo = this.state.findNodeById(connection.sourceNodeId);
|
|
1558
|
-
if (!sourceNodeInfo) {
|
|
1559
|
-
return { x: 0, y: 0 };
|
|
1560
|
-
}
|
|
1561
|
-
|
|
1562
|
-
const sourceNode = sourceNodeInfo.node;
|
|
1563
|
-
const sourcePoint = sourceNode.connectionPoints?.find(
|
|
1564
|
-
(p) => p.id === connection.sourcePointId
|
|
1565
|
-
);
|
|
1566
|
-
|
|
1567
|
-
if (!sourcePoint) {
|
|
1568
|
-
return { x: 0, y: 0 };
|
|
1569
|
-
}
|
|
1570
|
-
|
|
1571
|
-
// Calculate midpoint based on the connection point type
|
|
1572
|
-
if (sourcePoint.type === 'left' || sourcePoint.type === 'right') {
|
|
1573
|
-
const horizontalDist = endX - startX;
|
|
1574
|
-
|
|
1575
|
-
if (Math.abs(horizontalDist) < 30) {
|
|
1576
|
-
// For short horizontal connections
|
|
1577
|
-
const midY = (startY + endY) / 2;
|
|
1578
|
-
return {
|
|
1579
|
-
x: startX + (endX - startX) / 2,
|
|
1580
|
-
y: midY,
|
|
1581
|
-
};
|
|
1582
|
-
} else {
|
|
1583
|
-
// For regular connections starting horizontally
|
|
1584
|
-
const midX = startX + horizontalDist / 2;
|
|
1585
|
-
const midY = endY;
|
|
1586
|
-
return {
|
|
1587
|
-
x: midX,
|
|
1588
|
-
y: (startY + endY) / 2,
|
|
1589
|
-
};
|
|
1590
|
-
}
|
|
1591
|
-
} else {
|
|
1592
|
-
// 'top' or 'bottom'
|
|
1593
|
-
const verticalDist = endY - startY;
|
|
1594
|
-
|
|
1595
|
-
if (Math.abs(verticalDist) < 30) {
|
|
1596
|
-
// For short vertical connections
|
|
1597
|
-
const midX = (startX + endX) / 2;
|
|
1598
|
-
return {
|
|
1599
|
-
x: midX,
|
|
1600
|
-
y: startY + (endY - startY) / 2,
|
|
1601
|
-
};
|
|
1602
|
-
} else {
|
|
1603
|
-
// For regular connections starting vertically
|
|
1604
|
-
const midX = endX;
|
|
1605
|
-
const midY = startY + verticalDist / 2;
|
|
1606
|
-
return {
|
|
1607
|
-
x: (startX + endX) / 2,
|
|
1608
|
-
y: midY,
|
|
1609
|
-
};
|
|
1610
|
-
}
|
|
1611
|
-
}
|
|
1612
|
-
} catch (error) {
|
|
1613
|
-
return { x: 0, y: 0 };
|
|
1614
|
-
}
|
|
1615
|
-
}
|
|
1616
|
-
|
|
1617
|
-
saveConnectionLabel(connection: Connection, label: string) {
|
|
1618
|
-
// Update the connection label in the state
|
|
1619
|
-
this.state.connections = this.state.connections.map((conn) => {
|
|
1620
|
-
if (conn.id === connection.id) {
|
|
1621
|
-
return {
|
|
1622
|
-
...conn,
|
|
1623
|
-
label: label,
|
|
1624
|
-
};
|
|
1625
|
-
}
|
|
1626
|
-
return conn;
|
|
1627
|
-
});
|
|
1628
|
-
}
|
|
1629
|
-
}
|