SceneProp.value constructor
SceneProp.value(})
A row of a registered kind (SceneKind), backed by the KindNode's value map rather than a field: the one place a name meets a key.
The editing hints — unit, the soft range, angular — are what the
motion side's spec carried for the hand-written kinds; here they ride
the row, so the timeline and the inspector read one table.
Implementation
factory SceneProp.value(
String name,
ScenePropKind kind, {
required String of,
Object? defaultValue,
bool animatable = false,
SceneChoices? choices,
String? unit,
double? softMin,
double? softMax,
bool angular = false,
double? identity,
ScenePick? pick,
}) => SceneProp(
name,
kind,
kindName: of,
defaultValue: defaultValue,
animatable: animatable,
choices: choices,
unit: unit,
softMin: softMin,
softMax: softMax,
angular: angular,
identity: identity,
pick: pick,
read: (n) => (n as KindNode).values[name] ?? defaultValue,
write: (n, v) => (n as KindNode).values[name] = v,
);