Skip to content
This is the alpha v4 version website. Looking for the v3 documentation?

InlineFunctionConditional

Defined in: packages/sigma/src/types/styles.ts:157

Inline function conditional value. Chooses between then and else based on a function predicate. The function receives attributes, state, graph state, and the graph instance. Use this when neither whenState nor whenData shorthand forms are expressive enough.

Type Parameters

A

A extends Attributes

S

S

GS

GS

T

T

Properties

else?

optional else?: GraphicValue<A, S, GS, T>

Defined in: packages/sigma/src/types/styles.ts:160


then

then: GraphicValue<A, S, GS, T>

Defined in: packages/sigma/src/types/styles.ts:159


when

when: (attributes, state, graphState, graph) => boolean

Defined in: packages/sigma/src/types/styles.ts:158

Parameters

attributes

A

state

S

graphState

GS

graph

AbstractGraph

Returns

boolean