Home
API: forms

Interface: PartTag

lifecycle-kit

lifecycle-kit


lifecycle-kit / forms / PartTag

Interface: PartTag

Defined in: forms/path.ts:188

Which anatomical part a shape belongs to.

A flat label, not a tree. The assemblage stage has to put each part in a depth band, cast a directional light from one part onto the parts behind it, and give each band its own parallax offset. It cannot do any of that against an anonymous list of outlines — it would have to GUESS where one part ends and the next begins, and guessing wrong is precisely why the design doc says "parts currently read as stickers rather than anatomy".

So the emitting rule, which is the only thing that actually knows, says so. pair knows it just emitted a left and a right appendage; nothing downstream can recover that from coordinates alone.

Deliberately a string and not a closed enum. A closed set would be the catalogue failure one level down — capping the vocabulary at whatever someone had time to name, so that a rule producing a genuinely new kind of part has nowhere to put it. Consumers group by equality and ignore labels they do not recognise.

index disambiguates repetitions of the same part: repeat emitting three body segments tags them ("segment", 0..2), and pair tags a left and right as the same part with different indices. That is what lets a depth band be assigned per repetition — the near legs occlude the far ones.

Properties

index

readonly index: number

Defined in: forms/path.ts:190


part

readonly part: string

Defined in: forms/path.ts:189