@volter/world-console 3.0.17 → 3.0.18

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2179,7 +2179,9 @@ function CanvasSurface({ name, token, session, retry, snapshot, back, canWrite }
2179
2179
  onPaneClick={() => { setActive(null); setPicked(null); }}
2180
2180
  minZoom={0.03} maxZoom={1.5} nodesConnectable={false} elementsSelectable={false}
2181
2181
  panOnScroll zoomOnPinch zoomOnScroll={false} zoomOnDoubleClick={false} colorMode={dark ? 'dark' : 'light'} proOptions={{ hideAttribution: true }}>
2182
- <Background variant={BackgroundVariant.Dots} gap={28} size={1.4} />
2182
+ {/* dots the same size on screen at every zoom, their spacing doubling as the board zooms out (as a canvas app's
2183
+ grid steps), so the board shows where it is and how far it moved at any zoom */}
2184
+ <Background variant={BackgroundVariant.Dots} gap={28 * 2 ** Math.max(0, Math.ceil(Math.log2(16 / (28 * zoom))))} size={2 / zoom} />
2183
2185
  <Panel position="top-left" className="float layers">
2184
2186
  <div className="float-head">
2185
2187
  <button type="button" className="back" onClick={back} aria-label={`Back to ${name}`}>←</button>