Interface: AttrConstraints
Experimental
Constraint fields for leaf attributes. Which fields apply depends on valType; builders in attr.ts only expose the relevant ones.
Extended by
Properties
| Property | Modifier | Type | Description |
|---|---|---|---|
accepts? | readonly | (value) => boolean | Experimental enumerated only: also accept values this predicate approves, e.g. marker symbols registered at runtime (plan E8.11). Not serialized (plot-schema.json lists values only). |
arrayOk? | readonly | boolean | Experimental Accept per-point arrays in addition to a scalar value. |
clamp? | readonly | boolean | Experimental Clamp out-of-range numbers instead of falling back to dflt. |
dflt? | readonly | unknown | Experimental Default value (undefined means the attribute is absent from the full output when unset). |
extras? | readonly | readonly PrimitiveValue[] | Experimental Special values accepted verbatim: flaglist extras ('none'), numeric extras ('auto'), subplot-id extras ('paper', 'free'). |
flags? | readonly | readonly string[] | Experimental Flags for flaglist, joined with + (e.g. lines+markers). |
freeLength? | readonly | boolean | Experimental Allow info_array to be shorter/longer than items. |
items? | readonly | | AttrSpec<unknown, unknown> | readonly AttrSpec<unknown, unknown>[] | Experimental Item specs for info_array: one spec for every item, or one per position. |
max? | readonly | number | Experimental |
min? | readonly | number | Experimental Inclusive bounds for number, integer and info_array items. |
noBlank? | readonly | boolean | Experimental Reject empty strings (string). |
strict? | readonly | boolean | Experimental Reject non-string values instead of stringifying numbers (string). |
values? | readonly | readonly PrimitiveValue[] | Experimental Allowed values for enumerated. |