-
Notifications
You must be signed in to change notification settings - Fork 31
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 Text Annotation #405
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am ok with the way of managing the shape but the rendering can by improved IMHO
- label positioning: I proposed bc7c30f as a starting point. Label margin/spacing should be improved
- shape border position and size + configurability
In addition, style computation tests are missing fortext annotation
Rendering with master a7ece51
In the following, the text_annotations.bpmn file is used, but the same behaviour is observed with B.1.0
or B.2.0
Rendering with d30fc64
Rendering with bc7c30f
Improvement proposal, this needs some reworks to match what I propose. We may increase the stroke value
Rendering with bpmn-js@7.2.0 for reference
private readonly TEXT_ANNOTATION_BORDER_LENGTH = 20; | ||
private readonly TEXT_ANNOTATION_MARGIN_FROM_SHAPE = 1; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
❓ I guess we want a fixed size here. I am asking as we manage dynamic sizing for icons for now
See also #211
❓ I suggest to make this a style option for better extensibility. In addition, the border length seems to large and I would prefer to draw the stroke on shape bounds and use a margin for label (this seems to be the behaviour adopted by other BPMN vendors)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes the styling here is fixed
improvements for label pushed
always use align default style value
closes #386