itemOpacities

A mark's opacity from its opacity style attribute: one number for the whole mark, or — from a list or an application — one per item, 0 to 1, with an item the value gives none drawn whole.

@internote/canvas-sdkFunction
On this page
import { itemOpacities } from '@internote/canvas-sdk';

#Signature

(
    value: unknown,
    source: ItemSource | null,
    params: Record<string, number>,
    fallback?: number,
): {
    mark: number;
    items: number[] | null;
}

#Parameters

value
The attribute's value.
source
Where the readings come from, one entry per item.
params
The live parameter values.
fallback
The whole mark's opacity where the value gives none.

Declared in packages/canvas-sdk/src/data/item-looks.ts:385.

Last updated