Skip to content

Custom properties ​

Values you add to an object, to key, to bind, or to hand to a script.

What they are for ​

A shape has a position and an opacity because every shape does. A custom property is one you invent: glow, Layout/gap, state. It belongs to that object, and it can be keyed on a timeline, bound to data, or read by a script.

Two common reasons to add one:

  • A knob for a component. A name plate whose accent colour is a custom property is a name plate anyone can re-colour without opening it.
  • An input for a script. A script node's properties are its inputs, and they appear as Inputs.

Adding one ​

Three custom properties on a shape — a number, a boolean and a colour — each with its key and bind buttons

The + on the Custom properties heading picks the type: Number, Boolean, String, Color, Enum, Trigger or List.

The section appears on a shape, text, picture, layout or group only once it has one — the first one is added from a property group, a script node, or the artboard, which always show the section.

Naming, and grouping by name ​

The name is also the grouping. Type Layout/gap and the property sits in a group called Layout under the name gap: everything before the last slash is the group. Nested groups need no tree of their own — just a longer name.

Keying and binding ​

Each row carries the same two controls as any other: the diamond to key it, and the data glyph to bind it to a view-model property.

A third control, the link, does something useful in one step: it creates a matching view-model property and binds this one to it. One click turns a component's knob into a value a control system can fill. Its menu says where to make the property — the artboard's own view model, or one it reaches.

Unbinding it asks what to do with the property it made:

The input keeps its current value. The property can stay in the view model for later, or go with the binding.

with Unbind and Unbind and delete the property. When other bindings read the same property, it says how many, so you do not cut them by accident.

Types, and one limit ​

TypeEditor
Number, StringA field
BooleanA tick
ColorA swatch and a hex
EnumThe values of an enum in this document
TriggerThe word fires
ListShown, but a list cannot be handed to a script

See also ​

airZ Editor manual