Hello
I'm trying to create a visualization that is composed of multiple charts (a so-called "dashboard") but I'm probably using the wrong primitives or the wrong approach in composing them, because I'm running into issues.
You can see an example at [1] where I've only kept a single "box" out of a visualization that contains several such ones.
One problem, as you can see, is that I cannot enable axis grids, otherwise they extend well beyond their respective chart. This makes me think that I'm missing some sort of clipping container (a group?)
But I don't have a group with the exact size of the charting area: I only have a group for each "white box", with many (IMHO too many) signal expressions that are used to compute paddings and scale ranges to position the chart inside the box.
Is there a better approach? Should I create a group that is sized to the inner "charting area" and then plot the axes *outside* of it, so that I can use the group to clip the grids? Should I create nested groups for the white boxes and for the actual charts? More generally, how can I simplify the size computations between white boxes, charts and scales/axes?
Another related issue is the prevalence of "item.mark.group." expressions in my code. I found that expression by chance and now I'm using it every time I need to refer to the containing group attributes, mainly its size: item.mark.group.width and item.mark.group.height. Is this the wrong way to go about it? I tried using shorthands like width and height, but they always refer to the entire visualization. Should I define "width" and "height" signals inside each group, so that they override the outer ones?
Is there a "dashboard" example somewhere that I can study and learn from?
Tobia