Interface: AttrSpec<TIn, TFull>
Experimental
A leaf attribute.
Extends
Type Parameters
| Type Parameter | Default type | Description |
|---|---|---|
TIn | unknown | Accepted input type (what users write). |
TFull | unknown | Type after defaults (what later stages read). |
Properties
| Property | Modifier | Type | Description | Inherited from |
|---|---|---|---|---|
~full? | readonly | [TFull] | Experimental Phantom: full type. Never set at runtime. | - |
~in? | readonly | [TIn] | Experimental Phantom: input type. Never set at runtime. | - |
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). | AttrConstraints.accepts |
animatable? | readonly | boolean | Experimental Whether transitions can interpolate this attribute (E7.3). | NodeMeta.animatable |
arrayOk? | readonly | boolean | Experimental Accept per-point arrays in addition to a scalar value. | AttrConstraints.arrayOk |
clamp? | readonly | boolean | Experimental Clamp out-of-range numbers instead of falling back to dflt. | AttrConstraints.clamp |
deprecated? | readonly | string | Experimental Deprecation message. Using a deprecated attribute produces a deprecated issue. | NodeMeta.deprecated |
description? | readonly | string | Experimental Markdown description used for generated docs, JSDoc and editor hovers. | NodeMeta.description |
dflt? | readonly | unknown | Experimental Default value (undefined means the attribute is absent from the full output when unset). | AttrConstraints.dflt |
editType? | readonly | EditType | Experimental Pipeline stages invalidated by a change. Inherited from the nearest ancestor that declares one; the planner treats an undeclared root as calc. | NodeMeta.editType |
examples? | readonly | readonly unknown[] | Experimental Example values for docs. | NodeMeta.examples |
extras? | readonly | readonly PrimitiveValue[] | Experimental Special values accepted verbatim: flaglist extras ('none'), numeric extras ('auto'), subplot-id extras ('paper', 'free'). | AttrConstraints.extras |
flags? | readonly | readonly string[] | Experimental Flags for flaglist, joined with + (e.g. lines+markers). | AttrConstraints.flags |
freeLength? | readonly | boolean | Experimental Allow info_array to be shorter/longer than items. | AttrConstraints.freeLength |
items? | readonly | | AttrSpec<unknown, unknown> | readonly AttrSpec<unknown, unknown>[] | Experimental Item specs for info_array: one spec for every item, or one per position. | AttrConstraints.items |
kind | readonly | "attr" | Experimental | - |
max? | readonly | number | Experimental | AttrConstraints.max |
min? | readonly | number | Experimental Inclusive bounds for number, integer and info_array items. | AttrConstraints.min |
noBlank? | readonly | boolean | Experimental Reject empty strings (string). | AttrConstraints.noBlank |
plotlyPath? | readonly | string | Experimental Equivalent Plotly attribute path, when it differs from ours (compat-plotly, docs). | NodeMeta.plotlyPath |
role? | readonly | AttrRole | Experimental Docs grouping. | NodeMeta.role |
since? | readonly | string | Experimental Version in which the attribute first appeared. | NodeMeta.since |
strict? | readonly | boolean | Experimental Reject non-string values instead of stringifying numbers (string). | AttrConstraints.strict |
valType | readonly | | "string" | "number" | "boolean" | "function" | "integer" | "enumerated" | "flaglist" | "color" | "colorlist" | "colorscale" | "angle" | "subplotid" | "data_array" | "info_array" | "any" | Experimental | - |
values? | readonly | readonly PrimitiveValue[] | Experimental Allowed values for enumerated. | AttrConstraints.values |