@superwall/studio 2.4.0 → 2.5.1

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.
package/README.md CHANGED
@@ -110,6 +110,19 @@ version? }, onStep)` performs one and streams its steps, `status(surface)`
110
110
  has no project on disk) offers `["promote"]` and a `pick` that switches the
111
111
  surface, so the menu collapses to the picker and one button; the local
112
112
  studio keeps its own pick and sends a `version` only when one was chosen.
113
+ - `Canvas` is the zoomable stage the studio previews on, with
114
+ `useCanvasScale` for what it draws and a `CanvasHandle` ref (`fit`,
115
+ `actualSize`, `zoomStep`, `zoomTo`, `zoom()`, `pan`, `hold`). `inset` sets
116
+ the fit margin (48px by default). `contained` is for a stage inside a page
117
+ that scrolls, such as a chat: a plain wheel scrolls the page, a pinch or
118
+ ctrl-wheel zooms, a finger scrolls the page until the stage is zoomed in,
119
+ and the zoom keys and Space reach it only while it is hovered or focused.
120
+ Resizing the stage refits it, or re-centres it at the zoom it was left at.
121
+ `percent` formats a scale for a zoom readout.
122
+ - `chromeFor`, `deviceVariablesFor`, `isWebOnly` and `webViewportFor` are the
123
+ device rules the studio draws with: the frame chrome for a device (none on
124
+ web), the `device` variables a paywall reads, whether a paywall targets only
125
+ web, and the viewport a browser leaves on a device.
113
126
  - `StudioShell` (`position="absolute"` when the host owns the viewport) is
114
127
  the ink stage every screen expects, and it carries the `sw-studio` class
115
128
  the stylesheet scopes its base rules to.