ObjectValues

A plain object's values for Wardic: where each key it animates starts (the property's own value), and the ports core reads an Environment's values through, with no style, no layout to measure and no variables. A key the object doesn't have, whose value is neither a number nor a string, or that it can't write (read-only, or a getter with no setter) is an error naming it: Wardic writes no property the object didn't have.

import * as ObjectValues from "@wardic/object/ObjectValues"

const links = ObjectValues.startLinksOf({ opacity: 1 })
links.ownValue("opacity") // Option.some(1)

Variables

measuredPairs

const measuredPairs: MeasuredPairs.Shape;

The Measured pairs port: none.


ownValues

const ownValues: OwnValues.Shape;

The Own values port: values in the shape of their targets, and no style.


startLinksOf

const startLinksOf: (subject) => Spine.StartLinks;

subject's Base-value links: each key starts from its own value, the property as it is when the animation starts; there's no style to start from.

Parameters

subject

object

Returns

Spine.StartLinks


variableValues

const variableValues: VariableValues.Shape;

The Variable values port: none.

Functions

startLinksWith()

function startLinksWith(read): (subject) => StartLinks;

Base-value links on read: each key starts from what read gives for it when the animation starts, an error it throws naming the key; there's no style to start from. Another Environment of objects reads its own way: @wardic/three's finds a key on a mesh's material.

Parameters

read

(subject, key) => Option<string | number>

Returns

(subject) => StartLinks