Backgrounds
BlowBackground draws a dots, lines or cross pattern under the flow that pans and zooms with it. The toolbar drives its options - spacing per axis, dot and cross size, stroke width, offset, colour and a solid backdrop - and a second background stacked under the first turns the pattern into a grid with dots in it.
Press Tab to move between the nodes and edges of the diagram.
Press Enter or Space to select it, Shift with Enter to add it to the selection, the arrow keys to move the selected nodes, Delete to remove them and Escape to clear the selection. Press C to start a connection from it.
Press Enter or Space to select it, Delete to remove it and Escape to clear the selection. Press C to move its end to another node.
bit BlowTry it
- Pick a Variant:
Dots,LinesorCross. - Drag Gap to space the pattern closer or further apart, and tick Rows twice as far apart to space the vertical axis on its own.
- Drag Size to grow the dots or the arms of the crosses, and Line width to thicken the lines and crosses; each is off for the variant it does nothing to.
- Drag Offset to slide the pattern against the nodes without moving them.
- Switch Colour between the theme's pattern colour, a fixed grey and the accent colour applied by a CSS class.
- Tick Backdrop to paint a solid colour behind the pattern, and Grid underneath to stack a coarse grid of lines under it.
- Drag the background to pan and scroll to zoom: the pattern travels and scales with the nodes, and stays crisp at any zoom.
How it works
BlowBackgroundgoes inside the canvas. It is drawn in screen space from the current viewport, so it follows every pan and zoom without blurring.Variant(defaultDots) picks the shape;Gap(20) is the spacing in flow units, andGapXandGapYoverride one axis each - the rows box setsGapYto twice the gap.Sizeis the dot diameter or the cross arm length; left unset it is 1 for dots and 6 for crosses, which is where the slider starts each time you switch variant.LineWidth(1) is the stroke of lines and crosses.OffsetXandOffsetY(0) shift the pattern in flow units on top of the viewport's own translation.Colorleft unset takes--bit-blow-background-pattern, which follows the colour mode.PatternClassputs a class on the pattern's shape instead, so a stylesheet can colour it - here the dots'filland the lines'strokefrom--bit-blow-node-selected.ClassandStyledo the same for the background's container.BgColor(transparent) paints a solid colour behind the pattern - here--bit-blow-surface-muted, so it changes with the colour mode too.- Backgrounds stack: each is its own layer, painted in the order written. The grid is a
Linesbackground with four times the gap, placed before the pattern so it lies under it. FitViewOptionscaps the first fit at a zoom of 1, so a gap of 20 is 20 pixels on screen when the page opens.