Documentation
¶
Overview ¶
Package clihv is the output shape of the `skywire cli hv` commands that return a value. Most of them stream — a transcript, a page's console, CDP events as they arrive — and have no single result to shape; those are listed as streaming in the JSON-contract test instead.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Input ¶
type Input struct {
Action string `json:"action"` // click, drag or move
X float64 `json:"x"`
Y float64 `json:"y"`
// Drag only: X,Y is where the press landed and ToX,ToY where it was
// released, after Steps intermediate moves along the straight line.
ToX float64 `json:"to_x,omitempty"`
ToY float64 `json:"to_y,omitempty"`
Steps int `json:"steps,omitempty"`
RealPointerMoves int `json:"real_pointer_moves"`
FirstRealMove *[2]float64 `json:"first_real_move,omitempty"`
}
Input is what one `hv input` gesture did, and whether the page saw only that. RealPointerMoves counts trusted pointer moves the page received during the gesture that this command did not send: a hand on the mouse. When it is not zero the page saw a drag no test asked for, and the outcome is not that of the scripted input alone; FirstRealMove says where it went.