Skip to content

waygraph / applyDevicePhase

Function: applyDevicePhase() ​

applyDevicePhase(prev, phase): object

Defined in: src/demo/narration/device.ts:165

Carry-forward for device fixtures (mirror applyTodoPhase).

  • clear: hideDevice / device("desktop") with clear intent
  • set: author set device/viewport/touch this phase
  • keep: omit - preserve previous (whole episode remain)

Parameters ​

prev ​

DeviceState | undefined

phase ​

device? ​

DeviceState

deviceSync? ​

"set" | "clear" | "keep"

Returns ​

object

device ​

device: DeviceState | undefined

sync ​

sync: "set" | "clear" | "keep"

waygraph 0.18.3 (alpha) · Node 24+ · peer @playwright/test ^1.40.0 · syntax may change before 1.0: see what was removed