Canvas and runtime types
These contracts describe Pibbl’s Canvas host, root-surface configuration, and
the stable values returned by its runtime and state APIs. Import them with
type from @pibbl/core.
Canvas
Section titled “Canvas”Canvas is the supported host union: HTMLCanvasElement | OffscreenCanvas.
Pibbl owns at most one live mount for a host Canvas.
PibblAnimatedValueOptions
Section titled “PibblAnimatedValueOptions”PibblAnimatedValueOptions<T> supplies an animation definition or pure factory,
optional initial value, equality comparison, and diagnostic label.
PibblAnimationDefinition
Section titled “PibblAnimationDefinition”PibblAnimationDefinition<T> is an opaque immutable value description without a
clock or output binding.
PibblAnimationOptions
Section titled “PibblAnimationOptions”PibblAnimationOptions<T> configures defineAnimation with a finite duration,
synchronous sampler, and optional debug name.
PibblAnimationProgram
Section titled “PibblAnimationProgram”PibblAnimationProgram is an opaque immutable composition of tracks, sequences,
parallel work, waits, markers, and repeats.
PibblAnimationRepeatDirection
Section titled “PibblAnimationRepeatDirection”PibblAnimationRepeatDirection is normal, reverse, alternate, or
alternate-reverse.
PibblAnimationRepeatOptions
Section titled “PibblAnimationRepeatOptions”PibblAnimationRepeatOptions supplies a positive iteration count or infinity and
an optional repeat direction.
PibblAnimationSampleInput
Section titled “PibblAnimationSampleInput”PibblAnimationSampleInput<T> gives a custom sampler its activation value, local
time, and normalized progress.
PibblAnimationTarget
Section titled “PibblAnimationTarget”PibblAnimationTarget<T> provides from, to, and optional committed spring
velocity to a custom animation factory.
PibblConfig
Section titled “PibblConfig”PibblConfig selects either the fixed logical viewport configuration or the
responsive viewport configuration. The first pibbl() mount owns this choice.
PibblController
Section titled “PibblController”PibblController is the stable controller returned by pibbl(). Its dispose()
method is idempotent and releases runtime-owned resources for that mount.
PibblEasing
Section titled “PibblEasing”PibblEasing maps normalized progress to interpolation progress.
PibblFit
Section titled “PibblFit”PibblFit is the fixed-surface fitting mode. Fixed roots use centered contain
by default; the logical viewport remains distinct from CSS and backing pixels.
PibblFixedViewportConfig
Section titled “PibblFixedViewportConfig”PibblFixedViewportConfig configures a fixed logical viewport with optional fit, pixelRatio, and signal. Omitting it captures the Canvas’s initial logical
dimensions; the signal can abort runtime ownership.
PibblInterpolator
Section titled “PibblInterpolator”PibblInterpolator<T> produces a typed value between from and to for a
normalized progress value.
PibblKeyframesOptions
Section titled “PibblKeyframesOptions”PibblKeyframesOptions<T> supplies at least two values, duration, optional
offsets/easing/interpolator, and a debug name.
PibblPixelRatio
Section titled “PibblPixelRatio”PibblPixelRatio describes the backing-pixel density policy. It keeps logical
geometry independent from the Canvas backing-store density.
PibblPlayback
Section titled “PibblPlayback”PibblPlayback exposes readonly status and currentTime signals plus stable
play, pause, resume, cancel, finish, seek, reverse, and playback-rate controls.
PibblPlaybackEvent
Section titled “PibblPlaybackEvent”PibblPlaybackEvent describes start, iteration, marker, finish, and cancel
milestones delivered after rendering during Complete.
PibblPlaybackOptions
Section titled “PibblPlaybackOptions”PibblPlaybackOptions configures autoplay, conflict policy, debug name,
milestone delivery, and isolated error handling.
PibblPlaybackStatus
Section titled “PibblPlaybackStatus”PibblPlaybackStatus is idle, scheduled, running, paused, finished,
cancelled, or disposed.
PibblReactionOptions
Section titled “PibblReactionOptions”PibblReactionOptions accepts an optional debug name for a component-owned
useReaction lifecycle.
PibblRef
Section titled “PibblRef”PibblRef<T> is the stable mutable { current } object returned by useRef.
Writing current does not schedule rendering and its lifetime is one component
identity.
PibblRenderLayerComponentProps
Section titled “PibblRenderLayerComponentProps”PibblRenderLayerComponentProps supplies the style and normal Pibbl event, focus,
and participation fields reserved by a render layer.
PibblRenderLayerContext
Section titled “PibblRenderLayerContext”PibblRenderLayerContext exposes the layer’s owned OffscreenCanvas, current
resolved size, and a coalesced invalidation callback.
PibblRenderLayerDefinition
Section titled “PibblRenderLayerDefinition”PibblRenderLayerDefinition describes synchronous create, update, resize,
render, and optional disposal callbacks for an external raster layer.
PibblRenderLayerFrame
Section titled “PibblRenderLayerFrame”PibblRenderLayerFrame provides Pibbl logical frame time, delta, and next-frame
invalidation to one render callback.
PibblRenderLayerHit
Section titled “PibblRenderLayerHit”PibblRenderLayerHit<Target> reports a layer-local miss, an occluding block, or
a registered application target identity.
PibblRenderLayerInput
Section titled “PibblRenderLayerInput”PibblRenderLayerInput<Target> delivers coordinate input only after the layer
wins global reverse-paint arbitration, with layer-local coordinates and
winner-owned pointer capture controls.
PibblRenderLayerInteraction
Section titled “PibblRenderLayerInteraction”PibblRenderLayerInteraction<Props, Resources, Target> settles the interaction
snapshot that commits transactionally with a candidate bitmap.
PibblRenderLayerInteractionSnapshot
Section titled “PibblRenderLayerInteractionSnapshot”PibblRenderLayerInteractionSnapshot<Target> contains one generation’s target
declarations, hit test, and optional winner input handler.
PibblRenderLayerProps
Section titled “PibblRenderLayerProps”PibblRenderLayerProps<Props> combines custom layer props with the reserved Pibbl
component fields and rejects reserved custom names.
PibblRenderLayerSize
Section titled “PibblRenderLayerSize”PibblRenderLayerSize records logical and backing dimensions plus effective
pixel ratios for one layer frame.
PibblRenderLayerStyle
Section titled “PibblRenderLayerStyle”PibblRenderLayerStyle is the local box, layout, and filter style accepted by a
render layer.
PibblRenderLayerTarget
Section titled “PibblRenderLayerTarget”PibblRenderLayerTarget<Target> associates a stable application identity with
Pibbl handlers, cursor participation, and optional focus geometry.
PibblResponsiveViewportConfig
Section titled “PibblResponsiveViewportConfig”PibblResponsiveViewportConfig is { viewport: "responsive", pixelRatio?, signal? }. Its logical root follows CSS content-box pixels instead of a fixed
captured viewport.
PibblSpringOptions
Section titled “PibblSpringOptions”PibblSpringOptions configures a number-only analytic spring and its rest bounds.
PibblStepperOptions
Section titled “PibblStepperOptions”PibblStepperOptions<State, T> supplies the fixed step, state initialization,
step/read callbacks, optional completion predicate, elapsed clamp, and debug
name.
PibblTweenOptions
Section titled “PibblTweenOptions”PibblTweenOptions<T> supplies to, optional from, duration, easing,
interpolator, and debug name.
RenderingContext2D
Section titled “RenderingContext2D”RenderingContext2D is the 2D-context union for the supported Canvas hosts.
useCanvasContext() exposes it only while a Pibbl component is rendering.
Signal
Section titled “Signal”Signal<T> is a nominal readonly value with an explicit get(): T method.
SignalEquals
Section titled “SignalEquals”SignalEquals<T> compares the previous and candidate values. Pibbl uses
Object.is when no custom equality function is supplied.
SignalOptions
Section titled “SignalOptions”SignalOptions<T> accepts an optional equality function and debug name.
WritableSignal
Section titled “WritableSignal”WritableSignal<T> adds set(value), update(updater), and cached
asReadonly() to Signal<T>. set() treats functions as values.
API details from source
Section titled “API details from source”
Signal
Section titled “Signal”A readonly reactive value; get records a dependency when called by a tracked consumer.
interface Signal<T>Related API: Signal.
See also
Section titled “See also”View source — packages/core/src/lib/signals/types.ts:38
Properties and methods
Section titled “Properties and methods”
get
get: () => TReads the current value and records a dependency in the active tracked consumer. See Signal.
Returns
Section titled “Returns”The current value, recording a dependency when called from a tracked consumer.
SignalEquals
Section titled “SignalEquals”Compares previous and next values to decide whether a signal change should be published.
type SignalEquals<T> = (previous: T, next: T) => booleanRelated API: SignalEquals.
Parameters
Section titled “Parameters”-
previous— Previously stored value. -
next— Proposed replacement value.
Returns
Section titled “Returns”True when the values are equivalent and a change should be suppressed.
See also
Section titled “See also”View source — packages/core/src/lib/signals/types.ts:13
SignalOptions
Section titled “SignalOptions”Equality comparison and diagnostic naming options for a signal.
interface SignalOptions<T>Related API: SignalOptions.
See also
Section titled “See also”View source — packages/core/src/lib/signals/types.ts:24
Properties and methods
Section titled “Properties and methods”
equals (optional)
equals?: SignalEquals<T> | undefinedRelated API: SignalEquals.
Compares old and new values to suppress equivalent updates; defaults to Object.is. See SignalEquals.
debugName (optional)
debugName?: string | undefinedOptional label used in diagnostics. See SignalOptions.
WritableSignal
Section titled “WritableSignal”A signal with synchronous replacement and update operations and a readonly view.
interface WritableSignal<T> extends Signal<T>Related API: WritableSignal, Signal.
See also
Section titled “See also”View source — packages/core/src/lib/signals/types.ts:64
Properties and methods
Section titled “Properties and methods”
set
set: (value: T) => voidSynchronously replaces the value, publishing only when the equality comparison reports a change. See WritableSignal.
Parameters
Section titled “Parameters”value— Replacement value to compare with the currently stored value.
update
update: (update: (current: T) => T) => voidComputes a replacement from the current value and applies the signal’s equality policy. See WritableSignal.
Parameters
Section titled “Parameters”update— Synchronous function receiving the current value and returning its replacement.
asReadonly
asReadonly: () => Signal<T>Related API: Signal.
Returns a readonly signal view of this same reactive value. See Signal.
Returns
Section titled “Returns”A readonly view of the same signal, without set or update operations. See Signal .
get
get: () => TReads the current value and records a dependency in the active tracked consumer. See Signal.
Returns
Section titled “Returns”The current value, recording a dependency when called from a tracked consumer.
PibblAnimationDefinition
Section titled “PibblAnimationDefinition”An opaque, immutable description of an animation value.
interface PibblAnimationDefinition<T>Related API: PibblAnimationDefinition.
See also
Section titled “See also”View source — packages/core/src/lib/animation/types.ts:41
PibblAnimationOptions
Section titled “PibblAnimationOptions”Duration and sampling callback for a custom seekable animation definition.
interface PibblAnimationOptions<T>Related API: PibblAnimationOptions.
See also
Section titled “See also”View source — packages/core/src/lib/animation/types.ts:234
Properties and methods
Section titled “Properties and methods”
duration
readonly duration: numberDuration of the animation or transition in milliseconds. See PibblAnimationOptions.
sample
readonly sample: (input: PibblAnimationSampleInput<T>) => TRelated API: PibblAnimationSampleInput.
Samples a value from the captured initial value, local time, and normalized progress. See PibblAnimationSampleInput.
Parameters
Section titled “Parameters”input— Logical sample time, progress, and value captured at the start of the run. See PibblAnimationSampleInput .
Returns
Section titled “Returns”The value to publish for this sample.
debugName (optional)
readonly debugName?: string | undefinedOptional label used in diagnostics. See PibblAnimationOptions.
PibblAnimationProgram
Section titled “PibblAnimationProgram”An opaque, immutable composition of animation definitions.
interface PibblAnimationProgramRelated API: PibblAnimationProgram.
See also
Section titled “See also”View source — packages/core/src/lib/animation/types.ts:52
PibblAnimationRepeatDirection
Section titled “PibblAnimationRepeatDirection”Playback direction across iterations, including reversed and alternating runs.
type PibblAnimationRepeatDirection = | 'normal' | 'reverse' | 'alternate' | 'alternate-reverse'Related API: PibblAnimationRepeatDirection.
See also
Section titled “See also”View source — packages/core/src/lib/animation/types.ts:61
PibblAnimationRepeatOptions
Section titled “PibblAnimationRepeatOptions”Count and direction controls for a repeated animation program.
interface PibblAnimationRepeatOptionsRelated API: PibblAnimationRepeatOptions.
See also
Section titled “See also”View source — packages/core/src/lib/animation/types.ts:73
Properties and methods
Section titled “Properties and methods”
iterations
readonly iterations: numberNumber of times the program is repeated. See PibblAnimationRepeatOptions.
direction (optional)
readonly direction?: PibblAnimationRepeatDirection | undefinedRelated API: PibblAnimationRepeatDirection.
Direction in which this operation proceeds. See PibblAnimationRepeatDirection.
PibblAnimationSampleInput
Section titled “PibblAnimationSampleInput”Time and endpoint values supplied when sampling a seekable animation definition.
interface PibblAnimationSampleInput<T>Related API: PibblAnimationSampleInput.
See also
Section titled “See also”View source — packages/core/src/lib/animation/types.ts:210
Properties and methods
Section titled “Properties and methods”
initialValue
readonly initialValue: TValue captured at the start of this animation sample’s run. See PibblAnimationSampleInput.
localTime
readonly localTime: numberElapsed logical time within the sampled animation, in milliseconds. See PibblAnimationSampleInput.
progress
readonly progress: numberNormalized progress through the current animation or transition. See PibblAnimationSampleInput.
PibblAnimatedValueOptions
Section titled “PibblAnimatedValueOptions”Definition-based target animation with mount-owned equality and initial presentation.
interface PibblAnimatedValueOptions<T>Related API: PibblAnimatedValueOptions.
See also
Section titled “See also”View source — packages/core/src/lib/animation/types.ts:187
Properties and methods
Section titled “Properties and methods”
animation
readonly animation: PibblAnimationDefinition<T> | ((target: PibblAnimationTarget<T>) => PibblAnimationDefinition<T>)Related API: PibblAnimationDefinition, PibblAnimationTarget.
Immutable definition or pure factory receiving the hook-owned endpoints. Factories run synchronously during render and cannot write signals or call hooks.
See also
Section titled “See also”Parameters
Section titled “Parameters”target— Current endpoints and previous spring velocity. See PibblAnimationTarget.
Returns
Section titled “Returns”A concrete animation definition. See PibblAnimationDefinition.
equals (optional)
readonly equals?: SignalEquals<T> | undefinedRelated API: SignalEquals.
Comparison used to suppress equal targets. See SignalEquals.
initial (optional)
readonly initial?: T | undefinedInitial presented value; omitted initial values present the target without entrance motion. See useAnimatedValue.
debugName (optional)
readonly debugName?: string | undefinedOptional playback diagnostic label. See useAnimatedValue.
PibblAnimationTarget
Section titled “PibblAnimationTarget”Current endpoints and optional committed spring velocity supplied to an animation factory.
interface PibblAnimationTarget<T>Related API: PibblAnimationTarget.
See also
Section titled “See also”View source — packages/core/src/lib/animation/types.ts:173
Properties and methods
Section titled “Properties and methods”
from
readonly from: TLast presented value, or the explicit mount initial value. See useAnimatedValue.
to
readonly to: TLatest requested target. See useAnimatedValue.
velocity (optional)
readonly velocity?: number | undefinedCommitted analytic spring velocity, when the previous run is a spring. See spring.
PibblPlayback
Section titled “PibblPlayback”Mount-owned playback controls and reactive status/time for an animation program.
interface PibblPlaybackRelated API: PibblPlayback.
See also
Section titled “See also”View source — packages/core/src/lib/animation/types.ts:340
Properties and methods
Section titled “Properties and methods”
status
readonly status: Signal<PibblPlaybackStatus>Related API: Signal, PibblPlaybackStatus.
Reactive lifecycle state of the mounted playback. See PibblPlaybackStatus.
currentTime
readonly currentTime: Signal<number>Related API: Signal.
Reactive logical playback position in milliseconds. See PibblPlayback.
play
play: (options?: { readonly conflict?: 'error' | 'replace'; }) => voidQueues playback startup with an optional conflicting-writer replacement policy. See PibblPlayback.
Parameters
Section titled “Parameters”options— Writer-conflict policy; replacement must be explicitly requested.
pause
pause: () => voidQueues a pause without discarding the current playback position. See PibblPlayback.
resume
resume: () => voidQueues resumption from the paused playback position. See PibblPlayback.
cancel
cancel: () => voidQueues cancellation and release of the program’s writer leases. See PibblPlayback.
finish
finish: () => voidQueues completion at the program’s terminal value when supported. See PibblPlayback.
seek
seek: (milliseconds: number) => voidQueues a change to the playback’s logical position in milliseconds. See PibblPlayback.
Parameters
Section titled “Parameters”milliseconds— Logical playback position in milliseconds.
reverse
reverse: () => voidQueues reversal of the playback direction. See PibblPlayback.
setPlaybackRate
setPlaybackRate: (rate: number) => voidQueues a change to the rate at which logical playback time advances. See PibblPlayback.
Parameters
Section titled “Parameters”rate— Playback speed multiplier.
PibblPlaybackEvent
Section titled “PibblPlaybackEvent”Playback milestone information delivered after the scheduler completes the frame.
interface PibblPlaybackEventRelated API: PibblPlaybackEvent.
See also
Section titled “See also”View source — packages/core/src/lib/animation/types.ts:313
Properties and methods
Section titled “Properties and methods”
type
readonly type: "cancel" | "finish" | "iteration" | "marker" | "start"Related API: marker.
Selects "start" , "iteration" , "marker" , "finish" , "cancel" for type. See
PibblPlaybackEvent.
logicalTime
readonly logicalTime: numberLogical scheduler time in milliseconds. See PibblPlaybackEvent.
frameId
readonly frameId: numberIdentifier of the shared scheduler frame. See PibblPlaybackEvent.
programPath
readonly programPath: readonly number[]Indices identifying the program node that produced this event. See PibblPlaybackEvent.
iteration
readonly iteration: numberIndex of the current repetition. See PibblPlaybackEvent.
marker (optional)
readonly marker?: string | undefinedRelated API: marker.
Name or source marker identifying this milestone. See PibblPlaybackEvent.
PibblPlaybackOptions
Section titled “PibblPlaybackOptions”Playback startup, writer replacement, and lifecycle callback configuration.
interface PibblPlaybackOptionsRelated API: PibblPlaybackOptions.
See also
Section titled “See also”View source — packages/core/src/lib/animation/types.ts:382
Properties and methods
Section titled “Properties and methods”
autoplay (optional)
readonly autoplay?: boolean | undefinedWhether playback is requested automatically when the owner mounts. See PibblPlaybackOptions.
conflict (optional)
readonly conflict?: "error" | "replace" | undefinedSelects "error", "replace" for conflict. See PibblPlaybackOptions.
debugName (optional)
readonly debugName?: string | undefinedOptional label used in diagnostics. See PibblPlaybackOptions.
onEvent (optional)
readonly onEvent?: ((event: PibblPlaybackEvent) => void) | undefinedRelated API: PibblPlaybackEvent.
Receives lifecycle and milestone notifications. See PibblPlaybackEvent.
Parameters
Section titled “Parameters”event— Playback milestone or lifecycle event delivered during Complete. See PibblPlaybackEvent .
onError (optional)
readonly onError?: ((error: unknown) => void) | undefinedReceives failures reported by the owning runtime resource. See PibblPlaybackOptions.
Parameters
Section titled “Parameters”error— Failure reported by playback.
PibblPlaybackStatus
Section titled “PibblPlaybackStatus”The current lifecycle state of an animation playback.
type PibblPlaybackStatus = | 'idle' | 'scheduled' | 'running' | 'paused' | 'finished' | 'cancelled' | 'disposed'Related API: PibblPlaybackStatus.
See also
Section titled “See also”View source — packages/core/src/lib/animation/types.ts:299
PibblEasing
Section titled “PibblEasing”Maps normalized animation progress to an interpolation progress.
type PibblEasing = (progress: number) => numberRelated API: PibblEasing.
Parameters
Section titled “Parameters”progress— Normalized input progress.
Returns
Section titled “Returns”Eased progress used for interpolation.
See also
Section titled “See also”View source — packages/core/src/lib/animation/types.ts:19
PibblInterpolator
Section titled “PibblInterpolator”Produces an in-between value for a normalized interpolation progress.
type PibblInterpolator<T> = (from: T, to: T, progress: number) => TRelated API: PibblInterpolator.
Parameters
Section titled “Parameters”-
from— Value at the start of the interpolation. -
to— Value at the end of the interpolation. -
progress— Interpolation progress after easing.
Returns
Section titled “Returns”The interpolated value.
See also
Section titled “See also”View source — packages/core/src/lib/animation/types.ts:32
PibblKeyframesOptions
Section titled “PibblKeyframesOptions”Keyframe values, timing, and easing for a seekable animation definition.
interface PibblKeyframesOptions<T>Related API: PibblKeyframesOptions.
See also
Section titled “See also”View source — packages/core/src/lib/animation/types.ts:111
Properties and methods
Section titled “Properties and methods”
values
readonly values: readonly [T, T, ...T[]]Ordered values interpolated by the animation. See PibblKeyframesOptions.
duration
readonly duration: numberDuration of the animation or transition in milliseconds. See PibblKeyframesOptions.
offsets (optional)
readonly offsets?: readonly number[] | undefinedNormalized positions of the keyframes along the animation duration. See PibblKeyframesOptions.
easing (optional)
readonly easing?: PibblEasing | readonly PibblEasing[] | undefinedRelated API: easing, PibblEasing.
Maps normalized progress before interpolation. See PibblEasing.
interpolate (optional)
readonly interpolate?: PibblInterpolator<T> | undefinedRelated API: PibblInterpolator.
Produces a value between two endpoints at the supplied progress. See PibblInterpolator.
debugName (optional)
readonly debugName?: string | undefinedOptional label used in diagnostics. See PibblKeyframesOptions.
PibblSpringOptions
Section titled “PibblSpringOptions”Physical parameters and completion thresholds for an analytic spring definition.
interface PibblSpringOptionsRelated API: PibblSpringOptions.
See also
Section titled “See also”View source — packages/core/src/lib/animation/types.ts:137
Properties and methods
Section titled “Properties and methods”
from (optional)
readonly from?: number | undefinedStarting endpoint or value. See PibblSpringOptions.
to (optional)
readonly to?: number | undefinedDestination endpoint; omit when useAnimatedValue supplies the target. See PibblSpringOptions.
mass (optional)
readonly mass?: number | undefinedMass used by the spring or physics calculation. See PibblSpringOptions.
stiffness (optional)
readonly stiffness?: number | undefinedSpring stiffness controlling acceleration toward the target. See PibblSpringOptions.
damping (optional)
readonly damping?: number | undefinedSpring damping controlling the loss of velocity. See PibblSpringOptions.
initialVelocity (optional)
readonly initialVelocity?: number | undefinedStarting velocity of the spring. See PibblSpringOptions.
restSpeed (optional)
readonly restSpeed?: number | undefinedVelocity threshold used to determine when the spring has settled. See PibblSpringOptions .
restDelta (optional)
readonly restDelta?: number | undefinedDistance-from-target threshold used to determine when the spring has settled. See PibblSpringOptions.
maxDuration (optional)
readonly maxDuration?: number | undefinedMaximum duration allowed before the spring is forced to complete. See PibblSpringOptions .
debugName (optional)
readonly debugName?: string | undefinedOptional label used in diagnostics. See PibblSpringOptions.
PibblStepperOptions
Section titled “PibblStepperOptions”Fixed-step state-machine configuration; execution state is playback-owned.
interface PibblStepperOptions<State, T>Related API: PibblStepperOptions.
See also
Section titled “See also”View source — packages/core/src/lib/animation/types.ts:255
Properties and methods
Section titled “Properties and methods”
stepMilliseconds
readonly stepMilliseconds: numberFixed integration step in milliseconds. See PibblStepperOptions.
maxElapsedMilliseconds (optional)
readonly maxElapsedMilliseconds?: number | undefinedMaximum elapsed time admitted to fixed-step integration per frame. See PibblStepperOptions.
initial
readonly initial: (currentValue: T) => StateCreates playback-owned integration state from the current output value. See PibblStepperOptions.
Parameters
Section titled “Parameters”currentValue— Output signal value at the start of this run.
Returns
Section titled “Returns”Initial integration state for the run.
step
readonly step: (state: State, deltaMilliseconds: number) => StateAdvances the integration state by the supplied fixed timestep in milliseconds. See PibblStepperOptions.
Parameters
Section titled “Parameters”-
state— Integration state before this step. -
deltaMilliseconds— Fixed step duration in milliseconds.
Returns
Section titled “Returns”Integration state after this step.
read
readonly read: (state: State) => TExtracts the output value from the current integration state. See PibblStepperOptions.
Parameters
Section titled “Parameters”state— Current integration state.
Returns
Section titled “Returns”The output value represented by that state.
done (optional)
readonly done?: ((state: State) => boolean) | undefinedReports whether the integration state has reached completion. See PibblStepperOptions.
Parameters
Section titled “Parameters”state— Current integration state.
Returns
Section titled “Returns”True when the stepper has completed.
debugName (optional)
readonly debugName?: string | undefinedOptional label used in diagnostics. See PibblStepperOptions.
PibblTweenOptions
Section titled “PibblTweenOptions”Duration, easing, and optional custom interpolation between animation endpoints.
interface PibblTweenOptions<T>Related API: PibblTweenOptions.
See also
Section titled “See also”View source — packages/core/src/lib/animation/types.ts:87
Properties and methods
Section titled “Properties and methods”
from (optional)
readonly from?: T | undefinedStarting endpoint or value. See PibblTweenOptions.
to (optional)
readonly to?: T | undefinedDestination endpoint; omit when useAnimatedValue supplies the target. See PibblTweenOptions.
duration
readonly duration: numberDuration of the animation or transition in milliseconds. See PibblTweenOptions.
easing (optional)
readonly easing?: PibblEasing | undefinedRelated API: easing, PibblEasing.
Maps normalized progress before interpolation. See PibblEasing.
interpolate (optional)
readonly interpolate?: PibblInterpolator<T> | undefinedRelated API: PibblInterpolator.
Produces a value between two endpoints at the supplied progress. See PibblInterpolator.
debugName (optional)
readonly debugName?: string | undefinedOptional label used in diagnostics. See PibblTweenOptions.
PibblConfig
Section titled “PibblConfig”Canvas surface sizing, pixel density, and viewport configuration for a Pibbl mount.
type PibblConfig = | PibblFixedViewportConfig | PibblResponsiveViewportConfigRelated API: PibblConfig, PibblFixedViewportConfig, PibblResponsiveViewportConfig.
See also
Section titled “See also”View source — packages/core/src/lib/surface/types.ts:92
Properties and methods
Section titled “Properties and methods”
htmlOverlay (optional)
htmlOverlay?: HTMLElement | undefinedOpt-in host for application-owned HTML regions associated with this canvas. See PibblFixedViewportConfig. Opt-in host for application-owned HTML regions associated with this canvas. See PibblResponsiveViewportConfig.
signal (optional)
signal?: AbortSignal | undefinedRelated API: signal.
Abort signal governing the lifetime of this operation or mount. See PibblFixedViewportConfig. Abort signal governing the lifetime of this operation or mount. See PibblResponsiveViewportConfig.
viewport (optional)
viewport?: "responsive" | Readonly<{ width: number; height: number; }> | undefinedLogical viewport dimensions and fitting configuration. See PibblFixedViewportConfig. Logical viewport dimensions and fitting configuration. See PibblResponsiveViewportConfig .
pixelRatio (optional)
pixelRatio?: PibblPixelRatio | undefinedRelated API: PibblPixelRatio.
Requested backing-store pixel density. See PibblPixelRatio.
PibblFit
Section titled “PibblFit”How a fixed logical viewport fits inside its displayed canvas surface.
type PibblFit = | 'contain' | 'cover' | 'fill' | 'none' | 'scale-down'Related API: PibblFit.
See also
Section titled “See also”View source — packages/core/src/lib/surface/types.ts:7
PibblFixedViewportConfig
Section titled “PibblFixedViewportConfig”Fixed logical viewport dimensions and fitting policy for a canvas mount.
interface PibblFixedViewportConfigRelated API: PibblFixedViewportConfig.
See also
Section titled “See also”View source — packages/core/src/lib/surface/types.ts:29
Properties and methods
Section titled “Properties and methods”
htmlOverlay (optional)
htmlOverlay?: HTMLElement | undefinedOpt-in host for application-owned HTML regions associated with this canvas. See PibblFixedViewportConfig.
signal (optional)
signal?: AbortSignal | undefinedRelated API: signal.
Abort signal governing the lifetime of this operation or mount. See PibblFixedViewportConfig.
viewport (optional)
viewport?: Readonly<{ width: number; height: number; }> | undefinedLogical viewport dimensions and fitting configuration. See PibblFixedViewportConfig.
fit (optional)
fit?: PibblFit | undefinedRelated API: PibblFit.
Policy for fitting content within its available box. See PibblFit.
pixelRatio (optional)
pixelRatio?: PibblPixelRatio | undefinedRelated API: PibblPixelRatio.
Requested backing-store pixel density. See PibblPixelRatio.
PibblPixelRatio
Section titled “PibblPixelRatio”Requested backing-store density, either explicit or derived from the device.
type PibblPixelRatio = 'device' | numberRelated API: PibblPixelRatio.
See also
Section titled “See also”View source — packages/core/src/lib/surface/types.ts:20
PibblResponsiveViewportConfig
Section titled “PibblResponsiveViewportConfig”A viewport that follows the displayed canvas dimensions.
interface PibblResponsiveViewportConfigRelated API: PibblResponsiveViewportConfig.
See also
Section titled “See also”View source — packages/core/src/lib/surface/types.ts:65
Properties and methods
Section titled “Properties and methods”
htmlOverlay (optional)
htmlOverlay?: HTMLElement | undefinedOpt-in host for application-owned HTML regions associated with this canvas. See PibblResponsiveViewportConfig.
signal (optional)
signal?: AbortSignal | undefinedRelated API: signal.
Abort signal governing the lifetime of this operation or mount. See PibblResponsiveViewportConfig.
viewport
viewport: "responsive"Logical viewport dimensions and fitting configuration. See PibblResponsiveViewportConfig .
pixelRatio (optional)
pixelRatio?: PibblPixelRatio | undefinedRelated API: PibblPixelRatio.
Requested backing-store pixel density. See PibblPixelRatio.
PibblRenderLayerComponentProps
Section titled “PibblRenderLayerComponentProps”Pibbl-owned style, event, focus, and miss-handling props shared by external layers.
interface PibblRenderLayerComponentProps extends PibblEventHandlers, PibblEventFocusOptions, PibblEventParticipationOptionsRelated API: PibblRenderLayerComponentProps, PibblEventHandlers, PibblEventParticipationOptions.
See also
Section titled “See also”PibblEventParticipationOptions
View source — packages/core/src/lib/render-layer/types.ts:265
Properties and methods
Section titled “Properties and methods”
style (optional)
readonly style?: PibblRenderLayerStyle | undefinedRelated API: PibblRenderLayerStyle.
Declared presentation and layout properties. See PibblRenderLayerStyle.
View source — packages/core/src/lib/render-layer/types.ts:268
missBehavior (optional)
readonly missBehavior?: "block" | "pass-through" | "target-layer" | undefinedHow a layer miss participates in arbitration with lower painted content. See PibblRenderLayerComponentProps.
View source — packages/core/src/lib/render-layer/types.ts:273
pointerEvents (optional)
readonly pointerEvents?: PibblPointerEvents | undefinedRelated API: PibblPointerEvents.
Whether this content participates in pointer targeting. See PibblPointerEvents.
keyboardFocusable (optional)
readonly keyboardFocusable?: boolean | undefinedWhether the target may receive keyboard focus. See PibblEventFocusOptions.
keyboardNavigationBounds (optional)
readonly keyboardNavigationBounds?: Readonly<LayoutBox> | undefinedRelated API: LayoutBox.
Logical rectangle used for directional keyboard navigation. See LayoutBox.
PibblRenderLayerDefinition
Section titled “PibblRenderLayerDefinition”Resource creation, update, resizing, rendering, disposal, and interaction lifecycle of an external layer.
interface PibblRenderLayerDefinition<Props, Resources, Target extends object = object>Related API: PibblRenderLayerDefinition.
See also
Section titled “See also”View source — packages/core/src/lib/render-layer/types.ts:286
Properties and methods
Section titled “Properties and methods”
create
create: (context: Readonly<PibblRenderLayerContext>, initialProps: Readonly<Props>) => ResourcesRelated API: PibblRenderLayerContext.
Allocates application resources once for this mounted layer identity. See PibblRenderLayerDefinition.
Parameters
Section titled “Parameters”-
context— Mount-owned canvas, size, and invalidation services. See PibblRenderLayerContext . -
initialProps— Props supplied for the first mounted render.
Returns
Section titled “Returns”Persistent application resources retained until dispose.
View source — packages/core/src/lib/render-layer/types.ts:299
update (optional)
update?: ((resources: Resources, props: Readonly<Props>, context: Readonly<PibblRenderLayerContext>) => void) | undefinedRelated API: PibblRenderLayerContext.
Applies the latest props to existing resources before rendering. See PibblRenderLayerDefinition.
Parameters
Section titled “Parameters”-
resources— Resources previously returned by create. -
props— Latest component props. -
context— Mount-owned canvas, size, and invalidation services. See PibblRenderLayerContext .
View source — packages/core/src/lib/render-layer/types.ts:311
resize (optional)
resize?: ((resources: Resources, size: Readonly<PibblRenderLayerSize>, context: Readonly<PibblRenderLayerContext>) => void) | undefinedRelated API: PibblRenderLayerSize, PibblRenderLayerContext.
Adjusts resources to the newly resolved logical and backing-store dimensions. See PibblRenderLayerDefinition.
Parameters
Section titled “Parameters”-
resources— Resources previously returned by create. -
size— New logical and backing dimensions. See PibblRenderLayerSize. -
context— Mount-owned canvas, size, and invalidation services. See PibblRenderLayerContext .
View source — packages/core/src/lib/render-layer/types.ts:324
render
render: (resources: Resources, frame: Readonly<PibblRenderLayerFrame>, context: Readonly<PibblRenderLayerContext>) => voidRelated API: PibblRenderLayerFrame, PibblRenderLayerContext.
Draws this generation using Pibbl’s frame; invalidate only when another frame is needed. See PibblRenderLayerDefinition.
Parameters
Section titled “Parameters”-
resources— Resources previously returned by create. -
frame— Shared Pibbl frame timing and invalidation service. See PibblRenderLayerFrame . -
context— Mount-owned canvas, size, and invalidation services. See PibblRenderLayerContext .
View source — packages/core/src/lib/render-layer/types.ts:338
dispose (optional)
dispose?: ((resources: Resources, context: Readonly<PibblRenderLayerContext>) => void) | undefinedRelated API: PibblRenderLayerContext.
Releases application resources when the mounted layer is torn down. See PibblRenderLayerDefinition.
Parameters
Section titled “Parameters”-
resources— Resources previously returned by create, whose application-owned resources must be released. -
context— Mount-owned context for this resource lifetime. See PibblRenderLayerContext .
View source — packages/core/src/lib/render-layer/types.ts:351
interaction (optional)
interaction?: PibblRenderLayerInteraction<Props, Resources, Target> | undefinedRelated API: PibblRenderLayerInteraction.
Builds the interaction snapshot committed with the rendered bitmap. See PibblRenderLayerInteraction.
View source — packages/core/src/lib/render-layer/types.ts:356
PibblRenderLayerFrame
Section titled “PibblRenderLayerFrame”Shared scheduler timing and invalidation supplied to an external renderer for one frame.
interface PibblRenderLayerFrameRelated API: PibblRenderLayerFrame.
See also
Section titled “See also”View source — packages/core/src/lib/render-layer/types.ts:53
Properties and methods
Section titled “Properties and methods”
frameId
readonly frameId: numberIdentifier of the shared scheduler frame. See PibblRenderLayerFrame.
View source — packages/core/src/lib/render-layer/types.ts:55
time
readonly time: numberCurrent shared logical time in milliseconds. See PibblRenderLayerFrame.
View source — packages/core/src/lib/render-layer/types.ts:57
delta
readonly delta: numberElapsed frame time in milliseconds. See PibblRenderLayerFrame.
View source — packages/core/src/lib/render-layer/types.ts:59
deltaSeconds
readonly deltaSeconds: numberElapsed frame time in seconds. See PibblRenderLayerFrame.
View source — packages/core/src/lib/render-layer/types.ts:61
invalidate
invalidate: () => voidRequests another Pibbl render through the shared scheduler. See PibblRenderLayerFrame.
View source — packages/core/src/lib/render-layer/types.ts:63
PibblRenderLayerContext
Section titled “PibblRenderLayerContext”The Pibbl-owned offscreen canvas, current size, and frame-invalidation capability.
interface PibblRenderLayerContextRelated API: PibblRenderLayerContext.
See also
Section titled “See also”View source — packages/core/src/lib/render-layer/types.ts:72
Properties and methods
Section titled “Properties and methods”
canvas
readonly canvas: OffscreenCanvasCanvas surface associated with this resource or mount. See PibblRenderLayerContext.
View source — packages/core/src/lib/render-layer/types.ts:74
size
readonly size: PibblRenderLayerSizeRelated API: PibblRenderLayerSize.
Current logical dimensions, backing-store dimensions, and effective pixel ratios. See PibblRenderLayerSize.
View source — packages/core/src/lib/render-layer/types.ts:76
invalidate
invalidate: () => voidRequests another Pibbl render through the shared scheduler. See PibblRenderLayerContext.
View source — packages/core/src/lib/render-layer/types.ts:80
PibblRenderLayerHit
Section titled “PibblRenderLayerHit”A hit-test decision: pass through, block lower paint, or select one logical target.
type PibblRenderLayerHit<Target extends object> = | { /** Selects the kind of geometry, material, or result. See {@link PibblRenderLayerHit}. */ readonly kind: "miss"; } | { /** Selects the kind of geometry, material, or result. See {@link PibblRenderLayerHit}. */ readonly kind: "block"; } | { /** Selects the kind of geometry, material, or result. See {@link PibblRenderLayerHit}. */ readonly kind: "target"; /** The selected logical target or target configuration. See {@link PibblRenderLayerHit}. */ readonly target: Target; }Related API: PibblRenderLayerHit.
See also
Section titled “See also”PibblRenderLayerInteractionSnapshot
View source — packages/core/src/lib/render-layer/types.ts:100
Properties and methods
Section titled “Properties and methods”
kind
readonly kind: "block" | "miss" | "target"Selects the kind of geometry, material, or result. See PibblRenderLayerHit.
View source — packages/core/src/lib/render-layer/types.ts:103
PibblRenderLayerInput
Section titled “PibblRenderLayerInput”Pibbl-routed pointer input in layer-local coordinates with pointer-capture operations.
interface PibblRenderLayerInput<Target extends object>Related API: PibblRenderLayerInput.
See also
Section titled “See also”PibblRenderLayerInteractionSnapshot
View source — packages/core/src/lib/render-layer/types.ts:145
Properties and methods
Section titled “Properties and methods”
type
readonly type: "click" | "contextmenu" | "pointercancel" | "pointerdown" | "pointermove" | "pointerup" | "wheel"Selects "pointerdown" , "pointermove" , "pointerup" , "pointercancel" , "wheel" ,
"contextmenu" , "click" for type. See PibblRenderLayerInput.
View source — packages/core/src/lib/render-layer/types.ts:150
point
readonly point: Readonly<{ x: number; y: number; }>Pointer position in the external layer’s logical local coordinates. See PibblRenderLayerInput.
View source — packages/core/src/lib/render-layer/types.ts:162
hit
readonly hit: PibblRenderLayerHit<Target>Related API: PibblRenderLayerHit.
Target, block, or miss decision associated with the input. See PibblRenderLayerHit.
View source — packages/core/src/lib/render-layer/types.ts:175
originalEvent
readonly originalEvent: MouseEvent | PointerEvent | WheelEventThe originating browser event. See PibblRenderLayerInput.
View source — packages/core/src/lib/render-layer/types.ts:177
setPointerCapture
setPointerCapture: (pointerId: number) => voidCaptures the pointer for this logical target until release or cancellation. See PibblRenderLayerInput.
Parameters
Section titled “Parameters”pointerId— Pointer identifier from the routed pointer event.
View source — packages/core/src/lib/render-layer/types.ts:183
releasePointerCapture
releasePointerCapture: (pointerId: number) => voidReleases this target’s capture of the identified pointer. See PibblRenderLayerInput.
Parameters
Section titled “Parameters”pointerId— Pointer identifier from the routed pointer event.
View source — packages/core/src/lib/render-layer/types.ts:188
PibblRenderLayerInteraction
Section titled “PibblRenderLayerInteraction”Settles renderer resources into the interaction snapshot for a committed generation.
interface PibblRenderLayerInteraction<Props, Resources, Target extends object>Related API: PibblRenderLayerInteraction.
See also
Section titled “See also”PibblRenderLayerInteractionSnapshot
View source — packages/core/src/lib/render-layer/types.ts:239
Properties and methods
Section titled “Properties and methods”
settle
settle: (resources: Resources, props: Readonly<Props>, size: Readonly<PibblRenderLayerSize>) => PibblRenderLayerInteractionSnapshot<Target>Related API: PibblRenderLayerSize, PibblRenderLayerInteractionSnapshot.
Captures interaction state corresponding to the generation being committed. See PibblRenderLayerInteractionSnapshot.
Parameters
Section titled “Parameters”-
resources— Resources representing the rendered scene. -
props— Props used for the committed render. -
size— Logical and backing dimensions for this generation. See PibblRenderLayerSize .
Returns
Section titled “Returns”The interaction snapshot to commit together with the rendered bitmap. See PibblRenderLayerInteractionSnapshot .
View source — packages/core/src/lib/render-layer/types.ts:250
PibblRenderLayerInteractionSnapshot
Section titled “PibblRenderLayerInteractionSnapshot”Targets and hit testing committed atomically with one rendered bitmap generation.
interface PibblRenderLayerInteractionSnapshot<Target extends object>Related API: PibblRenderLayerInteractionSnapshot.
See also
Section titled “See also”View source — packages/core/src/lib/render-layer/types.ts:199
Properties and methods
Section titled “Properties and methods”
targets
readonly targets: Iterable<PibblRenderLayerTarget<Target>>Related API: PibblRenderLayerTarget.
Logical targets exposed by this committed generation. See PibblRenderLayerTarget.
View source — packages/core/src/lib/render-layer/types.ts:201
hitTest
hitTest: (point: Readonly<{ x: number; y: number; }>) => PibblRenderLayerHit<Target>Related API: PibblRenderLayerHit.
Resolves a layer-local point to a target, block, or miss decision. See PibblRenderLayerHit.
Parameters
Section titled “Parameters”point— Pointer position in layer-local logical coordinates.
Returns
Section titled “Returns”A target hit, a blocking hit, or a miss for this interaction generation. See PibblRenderLayerHit .
View source — packages/core/src/lib/render-layer/types.ts:209
onInput (optional)
onInput?: ((input: Readonly<PibblRenderLayerInput<Target>>) => void) | undefinedRelated API: PibblRenderLayerInput.
Receives Pibbl-routed input for this committed interaction generation. See PibblRenderLayerInteractionSnapshot.
Parameters
Section titled “Parameters”input— Pibbl-routed input for the committed interaction generation. See PibblRenderLayerInput .
View source — packages/core/src/lib/render-layer/types.ts:229
PibblRenderLayerProps
Section titled “PibblRenderLayerProps”Application props combined with layer props; reserved Pibbl prop collisions are rejected.
type PibblRenderLayerProps<Props> = Extract<keyof Props, PibblRenderLayerReservedProp> extends never ? Props & PibblRenderLayerComponentProps : neverRelated API: PibblRenderLayerProps, PibblRenderLayerComponentProps.
See also
Section titled “See also”PibblRenderLayerComponentProps
View source — packages/core/src/lib/render-layer/types.ts:373
Properties and methods
Section titled “Properties and methods”
style (optional)
readonly style?: PibblRenderLayerStyle | undefinedRelated API: PibblRenderLayerStyle.
Declared presentation and layout properties. See PibblRenderLayerStyle.
View source — packages/core/src/lib/render-layer/types.ts:268
missBehavior (optional)
readonly missBehavior?: "block" | "pass-through" | "target-layer" | undefinedHow a layer miss participates in arbitration with lower painted content. See PibblRenderLayerComponentProps.
View source — packages/core/src/lib/render-layer/types.ts:273
pointerEvents (optional)
readonly pointerEvents?: PibblPointerEvents | undefinedRelated API: PibblPointerEvents.
Whether this content participates in pointer targeting. See PibblPointerEvents.
keyboardFocusable (optional)
readonly keyboardFocusable?: boolean | undefinedWhether the target may receive keyboard focus. See PibblEventFocusOptions.
keyboardNavigationBounds (optional)
readonly keyboardNavigationBounds?: Readonly<LayoutBox> | undefinedRelated API: LayoutBox.
Logical rectangle used for directional keyboard navigation. See LayoutBox.
PibblRenderLayerSize
Section titled “PibblRenderLayerSize”Logical surface size, backing-store dimensions, and effective pixel ratios of an external render layer.
interface PibblRenderLayerSizeRelated API: PibblRenderLayerSize.
See also
Section titled “See also”View source — packages/core/src/lib/render-layer/types.ts:21
Properties and methods
Section titled “Properties and methods”
width
readonly width: numberHorizontal extent in the units of the containing geometry or surface. See PibblRenderLayerSize.
View source — packages/core/src/lib/render-layer/types.ts:26
height
readonly height: numberVertical extent in the units of the containing geometry or surface. See PibblRenderLayerSize.
View source — packages/core/src/lib/render-layer/types.ts:31
backingWidth
readonly backingWidth: numberWidth of the backing raster in physical pixels. See PibblRenderLayerSize.
View source — packages/core/src/lib/render-layer/types.ts:33
backingHeight
readonly backingHeight: numberHeight of the backing raster in physical pixels. See PibblRenderLayerSize.
View source — packages/core/src/lib/render-layer/types.ts:35
pixelRatioX
readonly pixelRatioX: numberEffective ratio of backing pixels to logical units on the x axis. See PibblRenderLayerSize.
View source — packages/core/src/lib/render-layer/types.ts:40
pixelRatioY
readonly pixelRatioY: numberEffective ratio of backing pixels to logical units on the y axis. See PibblRenderLayerSize.
View source — packages/core/src/lib/render-layer/types.ts:45
PibblRenderLayerStyle
Section titled “PibblRenderLayerStyle”Layout and outer Canvas composition style for an external render layer.
interface PibblRenderLayerStyle extends SystemStyle, BoxStyle, LayoutItemStyleRelated API: PibblRenderLayerStyle, SystemStyle, BoxStyle, LayoutItemStyle.
See also
Section titled “See also”PibblRenderLayerComponentProps
View source — packages/core/src/lib/render-layer/types.ts:91
Properties and methods
Section titled “Properties and methods”
maxHeight (optional)
maxHeight?: number | `${number}%` | undefinedMaximum permitted height. See Length.
padding (optional)
padding?: EdgeValues | undefinedRelated API: EdgeValues.
Insets between the border box and content box. See EdgeValues.
filter (optional)
filter?: PibblFilter | readonly PibblFilter[] | undefinedRelated API: PibblFilter.
Ordered pixel-only filters applied to the receiving primitive and its descendants. See PibblFilter.
left (optional)
left?: number | `${number}%` | undefinedLeft edge coordinate or inset. See Length.
View source — packages/core/src/lib/style/positioning.ts:127
top (optional)
top?: number | `${number}%` | undefinedTop edge value or top envelope guide. See Length.
View source — packages/core/src/lib/style/positioning.ts:129
width (optional)
width?: Length | undefinedRelated API: Length.
Horizontal extent in the units of the containing geometry or surface. See Length.
height (optional)
height?: Length | undefinedRelated API: Length.
Vertical extent in the units of the containing geometry or surface. See Length.
minWidth (optional)
minWidth?: number | `${number}%` | undefinedMinimum permitted width. See Length.
maxWidth (optional)
maxWidth?: number | `${number}%` | undefinedMaximum permitted width. See Length.
minHeight (optional)
minHeight?: number | `${number}%` | undefinedMinimum permitted height. See Length.
overflow (optional)
overflow?: "clip" | "visible" | undefinedSelects "visible", "clip" for overflow. See BoxStyle.
alignSelf (optional)
alignSelf?: "auto" | "center" | "end" | "flex-end" | "flex-start" | "start" | "stretch" | undefinedThis child’s cross-axis or block-axis alignment override. See LayoutItemStyle.
justifySelf (optional)
justifySelf?: "auto" | "center" | "end" | "start" | "stretch" | undefinedThis child’s inline-axis alignment override. See LayoutItemStyle.
flexBasis (optional)
flexBasis?: Length | undefinedRelated API: Length.
Initial main-axis size before flex growth or shrinkage. See Length.
flexGrow (optional)
flexGrow?: number | undefinedRelative share of positive free space assigned to this child. See LayoutItemStyle.
flexShrink (optional)
flexShrink?: number | undefinedRelative factor used when reducing main-axis size. See LayoutItemStyle.
gridColumnStart (optional)
gridColumnStart?: number | undefinedExplicit starting grid column. See LayoutItemStyle.
gridColumnSpan (optional)
gridColumnSpan?: number | undefinedNumber of columns occupied by this child. See LayoutItemStyle.
gridRowStart (optional)
gridRowStart?: number | undefinedExplicit starting grid row. See LayoutItemStyle.
gridRowSpan (optional)
gridRowSpan?: number | undefinedNumber of rows occupied by this child. See LayoutItemStyle.
transition (optional)
transition?: PibblTransitionBinding | undefinedRelated API: PibblTransitionBinding.
Visibility-transition binding applied to this primitive and its captured descendants. See SystemStyle.
custom (optional)
custom?: unknownApplication-defined style payload passed through the runtime. See SystemStyle.
PibblRenderLayerTarget
Section titled “PibblRenderLayerTarget”Stable target identity with event, cursor, and keyboard-focus metadata.
interface PibblRenderLayerTarget<Target extends object>Related API: PibblRenderLayerTarget.
See also
Section titled “See also”PibblRenderLayerInteractionSnapshot
View source — packages/core/src/lib/render-layer/types.ts:124
Properties and methods
Section titled “Properties and methods”
target
readonly target: TargetThe selected logical target or target configuration. See PibblRenderLayerTarget.
View source — packages/core/src/lib/render-layer/types.ts:126
handlers (optional)
Full type declaration
readonly handlers?: Partial<{ onAuxClick: PibblEventHandler<"auxclick">; onBeforeInput: PibblEventHandler<"beforeinput">; onBlur: PibblEventHandler<"blur">; onChange: PibblEventHandler<"change">; onClick: PibblEventHandler<"click">; onCompositionEnd: PibblEventHandler<"compositionend">; onCompositionStart: PibblEventHandler<"compositionstart">; onCompositionUpdate: PibblEventHandler<"compositionupdate">; onContextMenu: PibblEventHandler<"contextmenu">; onCopy: PibblEventHandler<"copy">; onCut: PibblEventHandler<"cut">; onDblClick: PibblEventHandler<"dblclick">; onDrag: PibblEventHandler<"drag">; onDragEnd: PibblEventHandler<"dragend">; onDragEnter: PibblEventHandler<"dragenter">; onDragLeave: PibblEventHandler<"dragleave">; onDragOver: PibblEventHandler<"dragover">; onDragStart: PibblEventHandler<"dragstart">; onDrop: PibblEventHandler<"drop">; onFocus: PibblEventHandler<"focus">; onFocusIn: PibblEventHandler<"focusin">; onFocusOut: PibblEventHandler<"focusout">; onGotPointerCapture: PibblEventHandler<"gotpointercapture">; onInput: PibblEventHandler<"input">; onKeyDown: PibblEventHandler<"keydown">; onKeyUp: PibblEventHandler<"keyup">; onLostPointerCapture: PibblEventHandler<"lostpointercapture">; onMouseDown: PibblEventHandler<"mousedown">; onMouseEnter: PibblEventHandler<"mouseenter">; onMouseLeave: PibblEventHandler<"mouseleave">; onMouseMove: PibblEventHandler<"mousemove">; onMouseOut: PibblEventHandler<"mouseout">; onMouseOver: PibblEventHandler<"mouseover">; onMouseUp: PibblEventHandler<"mouseup">; onPaste: PibblEventHandler<"paste">; onPointerCancel: PibblEventHandler<"pointercancel">; onPointerDown: PibblEventHandler<"pointerdown">; onPointerEnter: PibblEventHandler<"pointerenter">; onPointerLeave: PibblEventHandler<"pointerleave">; onPointerMove: PibblEventHandler<"pointermove">; onPointerOut: PibblEventHandler<"pointerout">; onPointerOver: PibblEventHandler<"pointerover">; onPointerRawUpdate: PibblEventHandler<"pointerrawupdate">; onPointerUp: PibblEventHandler<"pointerup">; onSelect: PibblEventHandler<"select">; onSelectionChange: PibblEventHandler<"selectionchange">; onTouchCancel: PibblEventHandler<"touchcancel">; onTouchEnd: PibblEventHandler<"touchend">; onTouchMove: PibblEventHandler<"touchmove">; onTouchStart: PibblEventHandler<"touchstart">; onWheel: PibblEventHandler<"wheel">; } & { onAuxClickCapture: PibblEventHandler<"auxclick">; onBeforeInputCapture: PibblEventHandler<"beforeinput">; onBlurCapture: PibblEventHandler<"blur">; onChangeCapture: PibblEventHandler<"change">; onClickCapture: PibblEventHandler<"click">; onCompositionEndCapture: PibblEventHandler<"compositionend">; onCompositionStartCapture: PibblEventHandler<"compositionstart">; onCompositionUpdateCapture: PibblEventHandler<"compositionupdate">; onContextMenuCapture: PibblEventHandler<"contextmenu">; onCopyCapture: PibblEventHandler<"copy">; onCutCapture: PibblEventHandler<"cut">; onDblClickCapture: PibblEventHandler<"dblclick">; onDragCapture: PibblEventHandler<"drag">; onDragEndCapture: PibblEventHandler<"dragend">; onDragEnterCapture: PibblEventHandler<"dragenter">; onDragLeaveCapture: PibblEventHandler<"dragleave">; onDragOverCapture: PibblEventHandler<"dragover">; onDragStartCapture: PibblEventHandler<"dragstart">; onDropCapture: PibblEventHandler<"drop">; onFocusCapture: PibblEventHandler<"focus">; onFocusInCapture: PibblEventHandler<"focusin">; onFocusOutCapture: PibblEventHandler<"focusout">; onGotPointerCaptureCapture: PibblEventHandler<"gotpointercapture">; onInputCapture: PibblEventHandler<"input">; onKeyDownCapture: PibblEventHandler<"keydown">; onKeyUpCapture: PibblEventHandler<"keyup">; onLostPointerCaptureCapture: PibblEventHandler<"lostpointercapture">; onMouseDownCapture: PibblEventHandler<"mousedown">; onMouseEnterCapture: PibblEventHandler<"mouseenter">; onMouseLeaveCapture: PibblEventHandler<"mouseleave">; onMouseMoveCapture: PibblEventHandler<"mousemove">; onMouseOutCapture: PibblEventHandler<"mouseout">; onMouseOverCapture: PibblEventHandler<"mouseover">; onMouseUpCapture: PibblEventHandler<"mouseup">; onPasteCapture: PibblEventHandler<"paste">; onPointerCancelCapture: PibblEventHandler<"pointercancel">; onPointerDownCapture: PibblEventHandler<"pointerdown">; onPointerEnterCapture: PibblEventHandler<"pointerenter">; onPointerLeaveCapture: PibblEventHandler<"pointerleave">; onPointerMoveCapture: PibblEventHandler<"pointermove">; onPointerOutCapture: PibblEventHandler<"pointerout">; onPointerOverCapture: PibblEventHandler<"pointerover">; onPointerRawUpdateCapture: PibblEventHandler<"pointerrawupdate">; onPointerUpCapture: PibblEventHandler<"pointerup">; onSelectCapture: PibblEventHandler<"select">; onSelectionChangeCapture: PibblEventHandler<"selectionchange">; onTouchCancelCapture: PibblEventHandler<"touchcancel">; onTouchEndCapture: PibblEventHandler<"touchend">; onTouchMoveCapture: PibblEventHandler<"touchmove">; onTouchStartCapture: PibblEventHandler<"touchstart">; onWheelCapture: PibblEventHandler<"wheel">; }> | undefinedRelated API: PibblEventHandler, blur.
Event handlers dispatched for this logical target. See PibblEventHandlers.
View source — packages/core/src/lib/render-layer/types.ts:128
pointerEvents (optional)
readonly pointerEvents?: PibblPointerEvents | undefinedRelated API: PibblPointerEvents.
Whether this content participates in pointer targeting. See PibblPointerEvents.
View source — packages/core/src/lib/render-layer/types.ts:130
cursor (optional)
readonly cursor?: string | undefinedCursor shown while this target owns pointer presentation. See PibblRenderLayerTarget.
View source — packages/core/src/lib/render-layer/types.ts:132
keyboardFocusable (optional)
readonly keyboardFocusable?: boolean | undefinedWhether the target may receive keyboard focus. See PibblRenderLayerTarget.
View source — packages/core/src/lib/render-layer/types.ts:134
keyboardNavigationBounds (optional)
readonly keyboardNavigationBounds?: Readonly<LayoutBox> | undefinedRelated API: LayoutBox.
Logical rectangle used for directional keyboard navigation. See LayoutBox.
View source — packages/core/src/lib/render-layer/types.ts:136
PibblRef
Section titled “PibblRef”A stable mutable container whose current value does not itself schedule rendering.
interface PibblRef<T>Related API: PibblRef.
See also
Section titled “See also”View source — packages/core/src/lib/hooks/use-ref.ts:8
Properties and methods
Section titled “Properties and methods”
current
current: T | undefinedMutable value retained by the ref container. See PibblRef.
PibblReactionOptions
Section titled “PibblReactionOptions”Options controlling when a signal reaction runs and how it is named for diagnostics.
interface PibblReactionOptionsRelated API: PibblReactionOptions.
See also
Section titled “See also”View source — packages/core/src/lib/hooks/use-reaction.ts:37
Properties and methods
Section titled “Properties and methods”
debugName (optional)
readonly debugName?: string | undefinedOptional label used in diagnostics. See PibblReactionOptions.
View source — packages/core/src/lib/hooks/use-reaction.ts:39
Canvas
Section titled “Canvas”A supported HTML or offscreen Canvas drawing surface.
type Canvas = HTMLCanvasElement | OffscreenCanvasRelated API: Canvas.
See also
Section titled “See also”View source — packages/core/src/lib/types.ts:260
PibblController
Section titled “PibblController”The stable controller of one canvas mount, including explicit idempotent disposal.
interface PibblControllerRelated API: PibblController.
See also
Section titled “See also”View source — packages/core/src/lib/types.ts:627
Properties and methods
Section titled “Properties and methods”
dispose
dispose: () => voidReleases every resource owned by this Pibbl mount. Safe to call repeatedly.
RenderingContext2D
Section titled “RenderingContext2D”A supported HTML or offscreen Canvas 2D rendering context.
type RenderingContext2D = CanvasRenderingContext2D | OffscreenCanvasRenderingContext2DRelated API: RenderingContext2D.
See also
Section titled “See also”View source — packages/core/src/lib/types.ts:268
Implementation guidance for agents
Section titled “Implementation guidance for agents”Read the Authoring, signals, and lifecycle companion for ownership, adaptation, failure modes, and verification. Agent start provides the version-selection workflow.
Complete minimal examples
Section titled “Complete minimal examples”- Mount, update, and dispose: Own one Pibbl root for a canvas and replace its content without creating another controller. Plain source
- Animate changing targets: Compare a tween and spring as the same target changes. Plain source
- Tween playback controls: Animate a signal and control the mounted playback with native buttons. Plain source
- Custom sampling and fixed steps: Combine a time-sampled sine wave with a fixed-step state machine. Plain source
- Compose keyframes and springs: Run two independent tracks together, then mark, wait, and repeat. Plain source
- Configure viewport and pixel density: Compare a fixed logical viewport with one that follows a resizable host. Plain source
- Component-owned state and reactions: Click to update a signal, derive a value, and publish an imperative effect after commit. Plain source
- Interactive bitmap layer: Draw a dot into an OffscreenCanvas and route clicks through Pibbl’s event boundary. Plain source
- Define a Canvas primitive: Supply synchronous drawing, style normalization, resolution, and opt-in measurement. Plain source
- Read and update signals: Use writable, readonly, and computed values with synchronous batching. Plain source
Documentation version
Section titled “Documentation version”Documentation built with @pibbl/core 0.0.2, revision 272a94a. ALPHA — NOT FOR PRODUCTION USE.