Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEAT] Render Lane (with SubLanes) #561

Merged
merged 13 commits into from
Sep 1, 2020
Merged

[FEAT] Render Lane (with SubLanes) #561

merged 13 commits into from
Sep 1, 2020

Conversation

aibcmars
Copy link
Contributor

closes #255

@aibcmars aibcmars added the BPMN rendering Something about the way the lib is rendering BPMN elements label Aug 31, 2020
Copy link
Member

@tbouffard tbouffard left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • missing tests (json parsing for sublanes)
  • IMHO too much things in this PR
  • doc not updated

src/component/mxgraph/MxGraphRenderer.ts Outdated Show resolved Hide resolved
src/component/mxgraph/config/StyleConfigurator.ts Outdated Show resolved Hide resolved
src/component/parser/json/converter/DiagramConverter.ts Outdated Show resolved Hide resolved
@@ -179,6 +179,10 @@ export default class StyleConfigurator {
style[mxConstants.STYLE_HORIZONTAL] = false;
style[mxConstants.STYLE_SWIMLANE_LINE] = 0; // hide the line between the title region and the content area

// TODO manage lane text area rendering. there is no Label neither the size available (we have only attribute name="Text of the Label")
// perhaps it can be calculated as a difference of starting point (either x or y) between pool, lane, sub-lane ?
style[mxConstants.STYLE_STARTSIZE] = 30;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

❓ did you try to decrease this value
30 is used for Pool because this seems to be the value a lot of modelers use.
Here we can do whatever we want for regular lanes
30 may be needed for lanes that have sub-lanes as in that case, the lane container seems to behave as the pool
⚠️ put it in a constant

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

with 30 it is centered vertically - tested with miwg-test-suite Reference files and BPMN editor
constant added, for pool also

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok perfect!

@tbouffard tbouffard added the enhancement New feature or request label Aug 31, 2020
@@ -6,6 +6,7 @@
<semantic:participant id="participant_1_id" name="Pool 1" processRef="WFP-6-" />
<semantic:participant id="participant_2_id" processRef="process_2" />
<semantic:participant id="participant_3_id" name="Black Box Process" />
<semantic:participant id="participant_4_id" name="Pool containing sublanes" processRef="process_4" />
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ sill missing tests for the JSon parser about the sublanes, the test here is to ensure the global parsing and the mxgraph model filling is done

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok, tests added in 422bfae

Copy link
Member

@tbouffard tbouffard left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thx for having taken the time integrating our feedbacks 😸

@csouchet csouchet merged commit 2cd9725 into master Sep 1, 2020
@csouchet csouchet deleted the 255-render_lane branch September 1, 2020 13:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
BPMN rendering Something about the way the lib is rendering BPMN elements enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[FEAT] Render the Lane
3 participants