Palette overflow, diagram resizes with pallete height

I’m trying to create a variation of the palette menu example Planogram. But i want to show all the nodes at once.

But i’m struggeling to get it right.

As shown in the screenshot i’m having this inner scrollbar, that i don’t want. I want to be able to scroll with the outer scrollbar.

  1. I’m unable to set the overflow hidden on the palette inner div.
  2. When i adjust the height of the pallette div to get rid of the inner scrollbar, then the diagramdiv also get’s larger.

So how can i set the overflow hidden for the inner div of the pallette. Or how can i prevent the diagramdiv stop growing larger according the palette.

Well, I see at least two plausible ways for you to see all of the (kinds of) nodes in that Palette. You could either increase the height of the Palette’s HTMLDivElement, or you could scale down the nodes so that they will fit in the Div.

The former you could implement in an “InitialLayoutCompleted” DiagramEvent listener that sets the height of the Div to the e.diagram.documentBounds.height pixels. GoJS Events -- Northwoods Software and GoJS Coordinate Systems-- Northwoods Software

Alternatively, you could implement the latter by setting Diagram.initialAutoScale to go.Diagram.Uniform on the Palette. Diagram | GoJS API
However if you have a lot of nodes there, they might appear rather small for them all to fit, in which case you’ll have to increase the height of the Div.