UI toolkit page is not covering whole screen in editor window?

I have main container which is set 100% height and width. To fill the screensize. In the container I have a scrollview which size depends on the content it has.
The problem is that in editor window ui page doesnt take the whole window but depends on the content. But in preview mode in ui builder everything is fine.



Setting height of template container to 100% solved the problem. Template container is root visual element which is returned by treeasset.Instantiate. Then just change style height of this container.

For anyone finding this answer, you can set the style height of the tree to a percentage like this:

tree.style.height = Length.Percent(100);