Commit Graph

477 Commits

Author SHA1 Message Date
Nico Rehwaldt 1333479815 fix(modeling/behavior): round label move adjustment
Ensure we don't return floating point numbers for conection label
adjustments calculated on connection changes.
2017-12-13 14:21:19 +01:00
Nico Rehwaldt a708a1cd4e chore(tests): adapt bendpoint tests to new cropping
Related to #684
2017-12-13 14:20:40 +01:00
Nico Rehwaldt 869e484601 chore(tests): use have.waypoints helper 2017-12-13 13:25:51 +01:00
Nico Rehwaldt f24b21684d test(cropping): add stress test
Related to #684
2017-12-13 13:25:51 +01:00
Nico Rehwaldt 408dd5383a chore(tests): localize test file 2017-12-13 13:25:51 +01:00
Nico Rehwaldt 5761e01ffe feat(modeling): adjust label location based on free space
Reacts on connection create, layout, reconnect and waypoint
update to find a suitable place for the label and reposition it.

Closes #738
2017-12-11 15:40:40 +01:00
Nico Rehwaldt cd24b27768 fix(copy-paste): ignore data associations during cloning
* use bpmnFactory for cloning to ensure all relevant
  elements have actual IDs
* don't copy dataAssociations, as they are visual elements
  that will be created during element re-connection

NOTE: This fixes data input association not properly being
wired during target replace, too.

Closes #694, #693
2017-12-11 15:14:31 +01:00
Nico Rehwaldt e7da5af0a1 chore(tests): depend on move module, where used
Tests would otherwise break in the future.

Related to bpmn-io/diagram-js#152
2017-12-10 23:04:11 +01:00
felixlinker 36a12396fd chore(renderer): extract BpmnRenderer utilities into util
Closes #731
2017-12-10 19:10:12 +01:00
Nico Rehwaldt e9eb9e374a fix(snapping): correct bendpoint snapping on shape move
Don't blindly snap first waypoint; instead, snap only bendpoints
that are manhattan layout aligned with other bendpoints (excluding
start and end).
2017-12-10 13:48:46 +01:00
Nico Rehwaldt f05ad02198 feat(layout): filter redundant connection waypoints 2017-12-10 12:29:54 +01:00
Nico Rehwaldt 7ffb865023 chore(project): consistent async error handling
Async utilities properly propagate _all_ errors to the
specified _done_ callback. Failing in _done_ does not
re-invoke it.

Adjustments made in

* Viewer#importXML
* Viewer#saveSVG
* Importer#importBpmnDiagram

Tests cleaned up to remove un-necessary `if (err) { ...` snippets.
2017-12-09 22:31:15 +01:00
Nico Rehwaldt 105f326dad chore(project): bump bpmn-moddle dependency
* unused namespace does not get serialized anymore

Closes #469
2017-12-09 22:30:56 +01:00
Nico Rehwaldt 50da47e1e1 fix(Viewer): trigger resized on attach
Ensure components get notified on `canvas.resized`, whenever
the Viewer instance gets attached.
2017-12-07 11:59:25 +01:00
Nico Rehwaldt 9b2a07d958 style(test): re-format test case 2017-11-23 11:00:23 +01:00
Nico Rehwaldt 2ef82970fd chore(Viewer): re-expose loaded definitions
The previous release kinda removed access to the currently
loaded definitions.

This restores access by exposing it by `Viewer#getDefinitions()`.
2017-11-23 09:49:54 +01:00
Nico Rehwaldt 642d7b88af chore(Viewer+Modeler): consistently name private instance variables
BREAKING CHANGE:

* definitions, container and moddle have been prefixed with
  an underscore (_) to denote they are private use.
2017-11-20 15:28:29 +01:00
Nico Rehwaldt ce45e9081b chore(project): bump bpmn-moddle dep
This improves the import and export of BPMN 2.0 XML documents

+ improves di prefix collision handling
+ proper deconflicting of prefixes during export
+ validate and detect non-BPMN root elements
+ replace underlying XML parser for higher speed and smaller
  bundle size
+ pass parse warnings with errors

NOTE:

* some error messages on broken XML may have changed
  due to changes in the underlying XML parser
2017-11-15 19:55:34 +01:00
felixlinker 0cb46183eb chore(draw/BpmnRenderer): exposed _drawPath helper
This allows extensions to reuse the internal drawPath utility.

Cf. #722 for context.
2017-11-13 09:56:02 +01:00
Nico Rehwaldt 9416eae126 chore(project): bump test dependency versions
* remove redundant karma-chai
2017-10-22 23:22:58 +02:00
Nico Rehwaldt 92aac008b8 chore(ci): use latest node for testing
This ensures we run against npm v5:

* bump wiredeps dependency version
* rebuild .wiredeps
* internalize test helpers from diagram-js
2017-10-11 15:19:36 +02:00
Philipp Fromme 9033094473 fix(renderer): prevent duplicate marker IDs
* when having more than one instance of bpmn-js on a page marker IDs got duplicated
2017-09-29 11:08:37 +02:00
pedesen 58207e7db2 feat(DropOnFlowBehavior): drop existing elements on flows
Closes #695
2017-07-27 15:15:08 +02:00
pedesen b1a544b84f fix(dropOnFlowBehavior): ignore drop point if bendpoint is inside shape
Closes #696
2017-07-27 13:41:50 +02:00
pedesen b234f17244 feat(snapping) snap on sequence flows
Closes #398
2017-07-27 13:41:45 +02:00
Philipp Fromme e797d9c142 feat(label-editing): improve text annotation editing
Related to camunda/camunda-modeler#564
2017-07-25 15:05:35 +02:00
Philipp Fromme 114da17403 fix(copy-paste): create new business object on paste
* fixes pasted elements having same business object
* removes temporary fix that prevents pasting twice

Closes #686
Closes camunda/camunda-modeler#561
2017-06-20 16:24:11 +02:00
Nico Rehwaldt 8015b21b15 fix(rules): allow TextAnnotation <-> Data(Store|Object) connection
Closes #687
2017-05-22 12:55:43 +02:00
Nico Rehwaldt 8e55edd80f chore(copy-paste): temporarily prevent consecutive paste
This prevents users from creating invalid
models due to IDs not properly being
generated on consecutive paste (#686).

Closes #688.
2017-05-19 13:01:57 +02:00
Nico Rehwaldt 83f55b1fb1 fix(modeling): handle label layouting edge case
Related to #669
2017-05-03 15:02:52 +02:00
Nico Rehwaldt 7d896855a9 fix(modeling): correct label line attachments not being recognized
* remove rounding where it does not matter
* work around some precision errors in logic
* adjust test cases (to higher precision)

Closes #669
2017-05-03 15:02:52 +02:00
Philipp Fromme 43a3b07ab2 fix(bpmn-rules): only connect flow nodes and artifacts through association
Closes camunda/camunda-modeler#554
2017-04-11 15:16:39 +02:00
Nico Rehwaldt 8d536f2cce style(modeling): reformat test case 2017-03-21 09:01:42 +01:00
Nico Rehwaldt 2fd46ac294 fix(modeling/layout): handle zero-length lines during adjustment
Closes #669
2017-03-21 09:01:21 +01:00
Philipp Fromme 12d700fd14 fix(drop-on-flow): disallow drop on flow label
Closes camunda/camunda-modeler#548
2017-03-10 12:47:23 +01:00
Philipp Fromme 79e8378db0 fix(label-support): fix positioning of label created on shape create
* make sure label shape is created with correct size
* make sure test varifies behaviour

Closes camunda/camunda-modeler#535
2017-03-07 15:22:43 +01:00
Nico Rehwaldt c5f48f5cd1 test(modeling): pass on Arch Linux 2017-03-02 11:53:42 +01:00
Nico Rehwaldt d1072471c4 fix(drop-on-sequence-flow): ensure correct behaviour
Closes #667
2017-03-02 11:45:34 +01:00
Philipp Fromme 81de98f786 feat(bpmn-renderer): use updated text util api
Related to bpmn-io/diagram-js#205
2017-03-02 10:55:40 +01:00
Ricardo Matias 1cb3a8eedc feat(util/model): avoid persisting empty property element containers
Closes #512
2017-02-14 15:43:58 +01:00
Ricardo Matias d8098c2feb feat(copy-paste): copy 'fill' and 'stroke' properties
Closes #640
2017-02-13 12:01:42 +01:00
Ricardo Matias 722c86beb2 feat(replace): persist colors when replacing an element
Related to #640
2017-02-13 12:01:42 +01:00
Ricardo Matias 2c51cfbe3d fix(util/model): able to clone Event Definitions extension elements
Related to camunda/camunda-modeler#516
Related to camunda/camunda-modeler#517
2017-02-10 09:47:59 +01:00
Ricardo Matias 1a4a8959fe fix(replace): make sure is respected for expanded sub processes
Closes camunda/camunda-modeler#511
2017-02-10 09:41:44 +01:00
Ricardo Matias b5c65f0b42 Revert "feat(util/model): avoid persisting empty property element containers"
This reverts commit 86c0a0aa75.
2017-02-08 15:44:29 +01:00
Ricardo Matias fdc756b442 test(util/model): able to clone 'inputOutput' property belonging to a subprocess
Closes camunda/camunda-modeler#513
2017-02-08 13:29:02 +01:00
Ricardo Matias 86c0a0aa75 feat(util/model): avoid persisting empty property element containers
Closes camunda/camunda-modeler#512
2017-02-08 09:50:12 +01:00
Ricardo Matias b37182b53b feat(util/model): make property cloning pluggable
This introduces a 'property.clone' event that allows
plugging into the cloning mechanism when cloning
nested extension elements.

Related to camunda/camunda-bpmn-moddle#35
2017-01-30 16:38:43 +01:00
Ricardo Matias 2ecb9aeae4 feat(copy-paste): clone properties when morphing to new element
Closes #648
2017-01-30 16:38:43 +01:00
Ricardo Matias 432d7f4b7c fix(replace): assign passed properties to businessObject before cloning 2017-01-30 16:23:57 +01:00