From 890cfe107f334063f452421f62b5571080bade22 Mon Sep 17 00:00:00 2001 From: Nico Rehwaldt Date: Sat, 26 Mar 2022 10:25:10 +0100 Subject: [PATCH 1/2] deps: bump BPMN modeling dependencies --- client/package-lock.json | 91 ++++++++++++++++------------------------ client/package.json | 8 ++-- 2 files changed, 39 insertions(+), 60 deletions(-) diff --git a/client/package-lock.json b/client/package-lock.json index 6056babd99..cbdab2b8b4 100644 --- a/client/package-lock.json +++ b/client/package-lock.json @@ -1082,12 +1082,12 @@ } }, "@bpmn-io/element-templates-validator": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/@bpmn-io/element-templates-validator/-/element-templates-validator-0.5.0.tgz", - "integrity": "sha512-v/gfuYs7AOsQUzGmWBEupFGZiylCzqapBoZrjavewnPPbDOzLvbHZ1bnYPre/7b/wdnf4ayx0bf/NCC/AEySVg==", + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/@bpmn-io/element-templates-validator/-/element-templates-validator-0.6.0.tgz", + "integrity": "sha512-GAs/04pjQGJKn02PwSpbmQ83pRBaOobpzVJwnv6dGQ9eg7mI0buBK27SOTNLexWyH+8Cm4NI32piLmkzx2IGVg==", "requires": { - "@camunda/element-templates-json-schema": "^0.7.0", - "@camunda/zeebe-element-templates-json-schema": "^0.1.0", + "@camunda/element-templates-json-schema": "^0.8.0", + "@camunda/zeebe-element-templates-json-schema": "^0.2.0", "json-source-map": "^0.6.1", "min-dash": "^3.8.1" } @@ -1144,9 +1144,9 @@ } }, "@bpmn-io/properties-panel": { - "version": "0.11.0", - "resolved": "https://registry.npmjs.org/@bpmn-io/properties-panel/-/properties-panel-0.11.0.tgz", - "integrity": "sha512-/1lZiwhCdAsapXKMjzVFc6jdyzU5Ue8wq/mMSFLVvAatxlHHrxTwYAqEW9zA0ZBqIm8JQbl6wptGMG/6ICZPGA==", + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/@bpmn-io/properties-panel/-/properties-panel-0.12.0.tgz", + "integrity": "sha512-YAZQQKdWMPQAzS50kZtaHIu5Ik0b/W85OKX4d90HL/xE1Tc9vryTs8SLcFwcPFyYXHPfr/VrI5Rl1341k0MPqg==", "requires": { "classnames": "^2.3.1", "min-dash": "^3.7.0", @@ -1171,14 +1171,14 @@ "integrity": "sha512-OWe9YQx3Vtnopz0trJCJVI3y7k2EfeR4QkKHfRhukcB7yxG4PD1FGaB5LAxc1wxp66V1S3LU4bqUpJdVhQhIww==" }, "@camunda/element-templates-json-schema": { - "version": "0.7.0", - "resolved": "https://registry.npmjs.org/@camunda/element-templates-json-schema/-/element-templates-json-schema-0.7.0.tgz", - "integrity": "sha512-ylBhHzAuzQjX+ZoZTPinHCsIaMa89fqyk10sxVQjgEm63+o40KMomjKf4EM2sXwiy72vDbjeXyb3Z56a7MTETQ==" + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/@camunda/element-templates-json-schema/-/element-templates-json-schema-0.8.0.tgz", + "integrity": "sha512-A9VgfJCr9GbDBbws48Ef7zv93pNy1EsjV/ijY0o0R4vUdbzMFbVvTIA+ypAlQC8xmAW1Sj/Gev8ocBM95djnpw==" }, "@camunda/zeebe-element-templates-json-schema": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/@camunda/zeebe-element-templates-json-schema/-/zeebe-element-templates-json-schema-0.1.0.tgz", - "integrity": "sha512-E5mie+Q+/0Rk12GerNRWZP6aIWFXo4KfC++6tFJUvKt8la4ZvsPpagB7F8Oiahd56/gUqOicJ7+yPyQ85JnFgA==" + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/@camunda/zeebe-element-templates-json-schema/-/zeebe-element-templates-json-schema-0.2.0.tgz", + "integrity": "sha512-2HF/kpcazyxzUBO5gKrhpQ5jvqrqW0wVAAf9ybbOOGhy/uXL+UG749R4OCUstwo1vpoOz5pDTrqOeUJEf7iQ0g==" }, "@colors/colors": { "version": "1.5.0", @@ -2451,9 +2451,9 @@ }, "dependencies": { "diagram-js": { - "version": "8.2.0", - "resolved": "https://registry.npmjs.org/diagram-js/-/diagram-js-8.2.0.tgz", - "integrity": "sha512-nbT6GSEbbKEVP8C4K8Olctsb5kgoDA/K+xuDZ3pnkkkmJwNW0hEyrVQGtwyYVldyUCoGFR7DI8NBJxNhleRgtg==", + "version": "8.2.1", + "resolved": "https://registry.npmjs.org/diagram-js/-/diagram-js-8.2.1.tgz", + "integrity": "sha512-R9D4CtRPCXFllGE4P/UTcK3fgYG/0WQfb87Pl7frdfnAbCbjZAM2vU0qgZaBhfU0cmW2OhdDPmEtz89brrOZDA==", "requires": { "css.escape": "^1.5.1", "didi": "^5.2.1", @@ -2502,11 +2502,11 @@ "integrity": "sha512-dXvRIUD+NuB/fByFP8r4/Vr8L9Buv/hdRQt0g5wzCHAoF+nW0C/Uv+EjRjwqqFr7AQr1XR+L1ADL3BDyKgeuWw==" }, "bpmn-js-properties-panel": { - "version": "1.0.0-alpha.5", - "resolved": "https://registry.npmjs.org/bpmn-js-properties-panel/-/bpmn-js-properties-panel-1.0.0-alpha.5.tgz", - "integrity": "sha512-AXunjjthnApd25M0A0OIVxwIWoJc/BvNVCObf0Ushh86PqESzjAbDkTdtbUGxnj4ukiFJB390K5b5NezUEL5IQ==", + "version": "1.0.0-alpha.7", + "resolved": "https://registry.npmjs.org/bpmn-js-properties-panel/-/bpmn-js-properties-panel-1.0.0-alpha.7.tgz", + "integrity": "sha512-RVm2xDSHSgOnBIbtUt8jW44krCB5IIN8/L+cKEWe9A7WZMiXglDw4swem3Wt8LiAvMNL1iFzlmj0v1LHQshtvA==", "requires": { - "@bpmn-io/element-templates-validator": "^0.5.0", + "@bpmn-io/element-templates-validator": "^0.6.0", "@bpmn-io/extract-process-variables": "^0.4.4", "array-move": "^3.0.1", "classnames": "^2.3.1", @@ -2514,7 +2514,7 @@ "min-dash": "^3.8.1", "min-dom": "^3.1.3", "preact-markup": "^2.1.1", - "semver": "^7.3.5" + "semver-compare": "^1.0.0" }, "dependencies": { "@bpmn-io/extract-process-variables": { @@ -2529,27 +2529,6 @@ "version": "2.3.1", "resolved": "https://registry.npmjs.org/classnames/-/classnames-2.3.1.tgz", "integrity": "sha512-OlQdbZ7gLfGarSqxesMesDa5uz7KFbID8Kpq/SxIoNGDqY8lSYs0D+hhtBXhcdB3rcbXArFr7vlHheLk1voeNA==" - }, - "lru-cache": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", - "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", - "requires": { - "yallist": "^4.0.0" - } - }, - "semver": { - "version": "7.3.5", - "resolved": "https://registry.npmjs.org/semver/-/semver-7.3.5.tgz", - "integrity": "sha512-PoeGJYh8HK4BTO/a9Tf6ZG3veo/A7ZVsYrSA6J8ny9nb3B1VrpkuN+z9OE5wfE5p6H4LchYZsegiQgbJD94ZFQ==", - "requires": { - "lru-cache": "^6.0.0" - } - }, - "yallist": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" } } }, @@ -2880,9 +2859,9 @@ } }, "camunda-bpmn-js": { - "version": "0.13.0-alpha.4", - "resolved": "https://registry.npmjs.org/camunda-bpmn-js/-/camunda-bpmn-js-0.13.0-alpha.4.tgz", - "integrity": "sha512-0COCkStS95+UekTMXgEbCpcOsjdR8tPNtKRejkgh8mvtlccLe+CatnY3TQWYuV0iHsGtgxLph9a4lOgDFg7/VQ==", + "version": "0.13.0-alpha.5", + "resolved": "https://registry.npmjs.org/camunda-bpmn-js/-/camunda-bpmn-js-0.13.0-alpha.5.tgz", + "integrity": "sha512-WabAjPmd+zapcZyOHHpg5z6pQjF+fcHChYKUgMz3ezJpNMWdMnFMsSGE9NUKoKLibCxF1hslf+YohT6nZzkS7A==", "requires": { "@bpmn-io/align-to-origin": "^0.7.0", "bpmn-js": "^9.0.3", @@ -2898,9 +2877,9 @@ }, "dependencies": { "diagram-js": { - "version": "8.2.0", - "resolved": "https://registry.npmjs.org/diagram-js/-/diagram-js-8.2.0.tgz", - "integrity": "sha512-nbT6GSEbbKEVP8C4K8Olctsb5kgoDA/K+xuDZ3pnkkkmJwNW0hEyrVQGtwyYVldyUCoGFR7DI8NBJxNhleRgtg==", + "version": "8.2.1", + "resolved": "https://registry.npmjs.org/diagram-js/-/diagram-js-8.2.1.tgz", + "integrity": "sha512-R9D4CtRPCXFllGE4P/UTcK3fgYG/0WQfb87Pl7frdfnAbCbjZAM2vU0qgZaBhfU0cmW2OhdDPmEtz89brrOZDA==", "requires": { "css.escape": "^1.5.1", "didi": "^5.2.1", @@ -4225,9 +4204,9 @@ "dev": true }, "diagram-js": { - "version": "7.8.2", - "resolved": "https://registry.npmjs.org/diagram-js/-/diagram-js-7.8.2.tgz", - "integrity": "sha512-+lzXUccgEYf9T5/1t2Y4MZyYirw47x8VEPyQ2RmDcZKO3m2iwEgyyFTOR7u6RuiVjusq7AnzgS+MVW0FhLd68A==", + "version": "8.2.1", + "resolved": "https://registry.npmjs.org/diagram-js/-/diagram-js-8.2.1.tgz", + "integrity": "sha512-R9D4CtRPCXFllGE4P/UTcK3fgYG/0WQfb87Pl7frdfnAbCbjZAM2vU0qgZaBhfU0cmW2OhdDPmEtz89brrOZDA==", "requires": { "css.escape": "^1.5.1", "didi": "^5.2.1", @@ -4256,9 +4235,9 @@ "integrity": "sha512-9u8xvMcSfuOiStv9bPdnRJQhGQXLKurew94n4GPQCdH1nj9QKC9ObbNoIpiRq8skiOBxKkt277PgOoFgAt3/rA==" }, "tiny-svg": { - "version": "2.2.2", - "resolved": "https://registry.npmjs.org/tiny-svg/-/tiny-svg-2.2.2.tgz", - "integrity": "sha512-u6zCuMkDR/3VAh83X7hDRn/pi0XhwG2ycuNS0cTFtQjGdOG2tSvEb8ds65VeGWc3H6PUjJKeunueXqgkZqtMsg==" + "version": "2.2.3", + "resolved": "https://registry.npmjs.org/tiny-svg/-/tiny-svg-2.2.3.tgz", + "integrity": "sha512-u5KGg889pD1W2c9GlLrTnAGzIkAO00/VXZGyzeiGHw+b9er8McLO0SnhxPQQDwDqFO0MrJ825AEsRUoTiDZFuQ==" } } }, @@ -7813,7 +7792,7 @@ "dependencies": { "commander": { "version": "2.15.1", - "resolved": "https://registry.npmjs.org/commander/-/commander-2.15.1.tgz", + "resolved": "http://registry.npmjs.org/commander/-/commander-2.15.1.tgz", "integrity": "sha512-VlfT9F3V0v+jr4yxPc5gg9s62/fIVWsd2Bk2iD435um1NlGMYdVCq+MjcXnhYq2icNOizHr1kK+5TI6H0Hy0ag==", "dev": true }, diff --git a/client/package.json b/client/package.json index e1d51bee03..3b222caa3b 100644 --- a/client/package.json +++ b/client/package.json @@ -11,15 +11,15 @@ "@bpmn-io/dmn-migrate": "^0.4.3", "@bpmn-io/extract-process-variables": "^0.4.3", "@bpmn-io/form-js": "^0.7.0", - "@bpmn-io/properties-panel": "^0.11.0", + "@bpmn-io/properties-panel": "^0.12.0", "@bpmn-io/replace-ids": "^0.2.0", "@ibm/plex": "^6.0.0", "@sentry/browser": "^6.3.6", "bpmn-js": "^9.0.3", - "bpmn-js-properties-panel": "^1.0.0-alpha.5", + "bpmn-js-properties-panel": "^1.0.0-alpha.7", "bpmn-moddle": "^7.1.2", "bpmnlint": "^7.2.1", - "camunda-bpmn-js": "^0.13.0-alpha.4", + "camunda-bpmn-js": "^0.13.0-alpha.5", "camunda-bpmn-moddle": "^6.1.1", "camunda-cmmn-moddle": "^1.0.0", "camunda-dmn-moddle": "^1.1.0", @@ -29,7 +29,7 @@ "cmmn-js-properties-panel": "^0.8.3", "codemirror": "^5.65.2", "debug": "^4.1.1", - "diagram-js": "^7.8.2", + "diagram-js": "^8.2.1", "diagram-js-direct-editing": "^1.6.3", "diagram-js-origin": "^1.3.2", "dmn-js": "^11.1.2", From c3d95fb90f453929ca11ae6fe95c91d0f2a77af3 Mon Sep 17 00:00:00 2001 From: Nico Rehwaldt Date: Sat, 26 Mar 2022 09:58:56 +0100 Subject: [PATCH 2/2] feat: integrate create/append anything Related to #2820 --- client/package-lock.json | 15 +++++++++++++++ client/package.json | 1 + client/src/app/tabs/bpmn/modeler/BpmnModeler.js | 11 ++++++++++- .../app/tabs/cloud-bpmn/modeler/BpmnModeler.js | 13 +++++++++++-- 4 files changed, 37 insertions(+), 3 deletions(-) diff --git a/client/package-lock.json b/client/package-lock.json index cbdab2b8b4..82459dd94b 100644 --- a/client/package-lock.json +++ b/client/package-lock.json @@ -2488,6 +2488,21 @@ } } }, + "bpmn-js-connectors-extension": { + "version": "github:bpmn-io/bpmn-js-connectors-extension#59247c27ef3c6997c199050d23a10898a7aa6869", + "from": "github:bpmn-io/bpmn-js-connectors-extension#template-categories-search", + "requires": { + "min-dom": "^3.1.3", + "tiny-svg": "^2.2.3" + }, + "dependencies": { + "tiny-svg": { + "version": "2.2.3", + "resolved": "https://registry.npmjs.org/tiny-svg/-/tiny-svg-2.2.3.tgz", + "integrity": "sha512-u5KGg889pD1W2c9GlLrTnAGzIkAO00/VXZGyzeiGHw+b9er8McLO0SnhxPQQDwDqFO0MrJ825AEsRUoTiDZFuQ==" + } + } + }, "bpmn-js-disable-collapsed-subprocess": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/bpmn-js-disable-collapsed-subprocess/-/bpmn-js-disable-collapsed-subprocess-0.1.3.tgz", diff --git a/client/package.json b/client/package.json index 3b222caa3b..4d5e06dab1 100644 --- a/client/package.json +++ b/client/package.json @@ -16,6 +16,7 @@ "@ibm/plex": "^6.0.0", "@sentry/browser": "^6.3.6", "bpmn-js": "^9.0.3", + "bpmn-js-connectors-extension": "github:bpmn-io/bpmn-js-connectors-extension#template-categories-search", "bpmn-js-properties-panel": "^1.0.0-alpha.7", "bpmn-moddle": "^7.1.2", "bpmnlint": "^7.2.1", diff --git a/client/src/app/tabs/bpmn/modeler/BpmnModeler.js b/client/src/app/tabs/bpmn/modeler/BpmnModeler.js index b83bf2020b..02ee9ccd4a 100644 --- a/client/src/app/tabs/bpmn/modeler/BpmnModeler.js +++ b/client/src/app/tabs/bpmn/modeler/BpmnModeler.js @@ -17,6 +17,10 @@ import globalClipboardModule from './features/global-clipboard'; import handToolOnSpaceModule from './features/hand-tool-on-space'; import propertiesPanelKeyboardBindingsModule from './features/properties-panel-keyboard-bindings'; +import connectorsExtensionModule from 'bpmn-js-connectors-extension'; + +import 'bpmn-js-connectors-extension/dist/connectors-extension.css'; + import Flags, { DISABLE_ADJUST_ORIGIN } from '../../../../util/Flags'; import 'camunda-bpmn-js/dist/assets/camunda-platform-modeler.css'; @@ -36,6 +40,10 @@ export default class PlatformBpmnModeler extends BpmnModeler { disableAdjustOrigin: Flags.get(DISABLE_ADJUST_ORIGIN), moddleExtensions: { ...(moddleExtensions || {}) + }, + connectorsExtension: { + appendAnything: true, + elementTemplateChooser: false } }); } @@ -48,7 +56,8 @@ const extensionModules = [ completeDirectEditingModule, globalClipboardModule, handToolOnSpaceModule, - propertiesPanelKeyboardBindingsModule + propertiesPanelKeyboardBindingsModule, + connectorsExtensionModule ]; PlatformBpmnModeler.prototype._modules = [ diff --git a/client/src/app/tabs/cloud-bpmn/modeler/BpmnModeler.js b/client/src/app/tabs/cloud-bpmn/modeler/BpmnModeler.js index 23c79af40f..eaaf2b9927 100644 --- a/client/src/app/tabs/cloud-bpmn/modeler/BpmnModeler.js +++ b/client/src/app/tabs/cloud-bpmn/modeler/BpmnModeler.js @@ -21,6 +21,10 @@ import Flags, { DISABLE_ADJUST_ORIGIN } from '../../../../util/Flags'; +import connectorsExtensionModule from 'bpmn-js-connectors-extension'; + +import 'bpmn-js-connectors-extension/dist/connectors-extension.css'; + import 'camunda-bpmn-js/dist/assets/camunda-cloud-modeler.css'; @@ -36,7 +40,11 @@ export default class CloudBpmnModeler extends BpmnModeler { super({ ...otherOptions, moddleExtensions: moddleExtensions || {}, - disableAdjustOrigin: Flags.get(DISABLE_ADJUST_ORIGIN) + disableAdjustOrigin: Flags.get(DISABLE_ADJUST_ORIGIN), + connectorsExtension: { + appendAnything: true, + elementTemplateChooser: false + } }); } } @@ -49,5 +57,6 @@ CloudBpmnModeler.prototype._modules = [ completeDirectEditingModule, globalClipboardModule, handToolOnSpaceModule, - propertiesPanelKeyboardBindingsModule + propertiesPanelKeyboardBindingsModule, + connectorsExtensionModule ];