Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Conversation

paula-stacho
Copy link
Collaborator

@paula-stacho paula-stacho commented Oct 13, 2025

Description

The layered and force algorithms are intended for diagrams with both nodes and edges. A bit surprisingly, when no edges are provided to the layered algorithm, it doesn't apply the node spacing we've specified and instead uses the default (20). The issue is actually present in the tests as well, I just didn't realise before that there was a spacing config that was ignored.

ELK provides other algorithms for unconnected nodes, like rectpacking. I was thinking how to best combine this with our existing direction options - here I'm adding it under a RECTANGLE option. Additionally I've added options, so far only aspectRatio but there might be more that are useful in the future.

This is a breaking change for the util, so the next bump will be major.

Before

Screenshot 2025-10-13 at 14 02 00

After

Screenshot 2025-10-13 at 14 01 26

@paula-stacho paula-stacho merged commit 5384a21 into main Oct 14, 2025
5 checks passed
@paula-stacho paula-stacho deleted the no-edges-layout branch October 14, 2025 08:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.