Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Be able to create an element from an element template

See original GitHub issue

Is your feature request related to a problem? Please describe

As a user I am able to change an element to an element template of a specific type. I am also able to declare an element template as default; this ensures it is applied as the element is created.

What I am not able to do yet is to create an element of a specific type, i.e. because I want to create it right off the palette or append it:

capture Vzsshq_optimized

We have a workaround for what I envision: Bootstrap the element (with all required extensions) manually, cf. ConnectorsExtension. That, however forces me to know all element templates in advance; it is not a solution applicable for general template support.

Describe the solution you’d like

  • It is possible to create an element of a specific type similar to ElementFactory#create**, i.e. elementTemplates.createElement(template: ElementTemplate): DiagramElement - The element shall not be added to the canvas yet, but it shall be already configured to the extend needed.

Describe alternatives you’ve considered

Decide this is not a direction we want to go.

Additional context

This pops up in the context of connectors, specifically in the realm of how to integrate them nicely into the existing modeling UX.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:11 (11 by maintainers)

github_iconTop GitHub Comments

nikkucommented, Feb 23, 2022

To clarify: This feature request is about creating a diagram element of a specific type outside the core modeling cycle.

The use-case is that I want to pull that element out from the palette (into “hover state”), and preview it accordingly (or add it using existing modeling APIs).

Hope this answers your question.

pinussilvestruscommented, Mar 11, 2022

Along with our Reflect & Plan, and given our current priorities (Web Modeler & Connectors), I will descope the API for Camunda Platform for now. We can (easily) add the same foundations to the element-templates provider once we need it. I added another issue for that:

Read more comments on GitHub >

github_iconTop Results From Across the Web

The Content Template element - HTML - MDN Web Docs
The <template> HTML element is a mechanism for holding HTML that is not to be rendered immediately when a page is loaded but...
Read more >
Template element - The Modern JavaScript Tutorial
A built-in <template> element serves as a storage for HTML markup templates. The browser ignores its contents, only checks for syntax ...
Read more >
Create an Element Template - Weebly Cloud
Templates are the core component of an element. The template is the actual HTML content that will be rendered on a users page....
Read more >
Understanding the Template Element in HTML
Creating a template is simple. It is done by specifying the <template> element and giving it an appropriate ID. <template id="content- ...
Read more >
OSIsoft: Create/edit element template attributes. v2010
When thinking about template use, it is important to decide what attributes to define in the template, as opposed to leaving some attributes ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Post

No results found

github_iconTop Related Hashnode Post

No results found