Skip to content

Release v3.2.0

Choose a tag to compare

@github-actions github-actions released this 04 Sep 06:56
16f38f6

Added

  • Canvas is back as a panel, and carries an Extent — the coordinate space a child's Canvas.Left/Canvas.Top pair is measured against. It was dropped on the argument that FreeformArrangement already covers absolute placement, but the two sit at different levels: a FreeformArrangement arranges a layout slot's content with one variant per size class, while a Canvas places elements inside a single coordinate space in the element tree. Without the panel there was nowhere for a free-placement design surface to land.
  • isCanvas recognizes a canvas by its extent, the same way the other panel guards recognize theirs by the property each one alone declares. The old Canvas declared no properties at all, which is why nothing could tell it from a plain Panel — and why it could be removed without anything noticing.

Changed

  • The React renderer arranges a canvas: it becomes the positioned ancestor its children are placed against, sized to its extent, with a child that names any of Canvas.Left, Canvas.Top, Canvas.Right or Canvas.Bottom placed absolutely. A child that names none stays in flow rather than being pinned to the origin.
  • The name follows @cratis/components' Canvas, which is the surface a Cratis application actually draws one on, rather than introducing a second word for the same thing.