Skip to main content

Interface: TransformMatchingCodeOptions

Defined in: src/animation/transform/TransformMatchingCode.ts:28

Extends​

Properties​

duration?​

optional duration: number

Defined in: src/animation/Animation.ts:16

Duration of the animation in seconds (default: 1)

Inherited from​

AnimationOptions.duration


fadeRatio?​

optional fadeRatio: number

Defined in: src/animation/transform/TransformMatchingCode.ts:36

Fade duration as a fraction of the total duration (0 to 0.5). Default: 0.25.


fadeTransformMismatches?​

optional fadeTransformMismatches: boolean

Defined in: src/animation/transform/TransformMatchingCode.ts:48

When transforming mismatches, cross-fade the moving unit (fade out, then fade in) instead of keeping it fully visible. Default: false.


keyFunc()?​

optional keyFunc: (token) => string

Defined in: src/animation/transform/TransformMatchingCode.ts:34

Key function for matching. Units with the same key match. Default keys a token by its syntax type and text, so unchanged tokens match even when they move.

Parameters​

token​

CodeToken

Returns​

string


matchBy?​

optional matchBy: CodeMatchBy

Defined in: src/animation/transform/TransformMatchingCode.ts:38

Match whole lines or individual tokens. Default: 'token'.


rateFunc?​

optional rateFunc: RateFunction

Defined in: src/animation/Animation.ts:18

Rate function controlling the animation's pacing (default: smooth)

Inherited from​

AnimationOptions.rateFunc


shift?​

optional shift: [number, number, number]

Defined in: src/animation/Animation.ts:20

Shift direction for fade animations

Inherited from​

AnimationOptions.shift


transformMismatches?​

optional transformMismatches: boolean

Defined in: src/animation/transform/TransformMatchingCode.ts:43

Transform unmatched units into each other (true) instead of fading them (false). Leftover units still fade. Default: false.