Skip to content

@jsvision/ui / SurfaceViewOptions

Interface: SurfaceViewOptions ​

Defined in: ui/src/surface/surface-view.ts:29

Options for a SurfaceView.

Properties ​

delta? ​

optional delta?: Signal<Point>

Defined in: ui/src/surface/surface-view.ts:33

Two-way scroll offset {x,y}; defaults to signal({x:0,y:0}). The caller drives it (e.g. a ScrollBar).


onScroll? ​

optional onScroll?: (delta) => void

Defined in: ui/src/surface/surface-view.ts:35

Fired when delta changes (skips the initial value and same-coordinate no-op writes).

Parameters ​

delta ​

Point

Returns ​

void


surface ​

surface: SurfaceSource

Defined in: ui/src/surface/surface-view.ts:31

The bound surface (static, null, or a reactive accessor — swap-aware).