import type { DataItem } from "../../core/render/Component"; import type { Color } from "../../core/util/Color"; import type { Time } from "../../core/util/Animation"; import type { Flow, IFlowDataItem } from "./Flow"; import type { ColorSet } from "../../core/util/ColorSet"; import type { PatternSet } from "../../core/util/PatternSet"; import type { Pattern } from "../../core/render/patterns/Pattern"; import type { Container } from "../../core/render/Container"; import type { Bullet } from "../../core/render/Bullet"; import type * as d3sankey from "d3-sankey"; import { Label } from "../../core/render/Label"; import { Series, ISeriesSettings, ISeriesDataItem, ISeriesPrivate, ISeriesEvents } from "../../core/render/Series"; import { ListTemplate } from "../../core/util/List"; import { FlowNode } from "./FlowNode"; export interface IFlowNodesDataItem extends ISeriesDataItem { /** * Node name. */ name: string; /** * The node element. */ node: FlowNode; /** * Node label. */ label: Label; /** * Node color. */ fill: Color; /** * Node pattern. * * @see {@link https://www.amcharts.com/docs/v5/concepts/colors-gradients-and-patterns/patterns/} for more info * @since 5.10.0 */ fillPattern: Pattern; /** * Marks a placeholder node, made for a link that has no source or target * ID. It is not shown, and its links fade out toward it. */ unknown: boolean; /** * @ignore */ d3SankeyNode: d3sankey.SankeyNode; /** * Sum of values of all incoming links. */ sumIncoming: number; /** * Sum of values of all outgoing links. */ sumOutgoing: number; /** * @ignore */ sumIncomingWorking: number; /** * @ignore */ sumOutgoingWorking: number; /** * Sum of values of all links: incoming and outgoing. */ sum: number; /** * @ignore */ sumWorking: number; /** * Data items of the links that come into the node. */ incomingLinks: Array>; /** * Data items of the links that go out of the node. */ outgoingLinks: Array>; /** * Depth of the node. */ depth: number; } export interface IFlowNodesSettings extends ISeriesSettings { /** * Field in data that marks a node as "unknown" (`true`): a hidden * placeholder that its links fade out toward. * * @default "unknown" */ unknownField?: string; /** * Field in data that holds the node's name. * * @default "id" */ nameField?: string; /** * Field in data that, when `true`, makes the node start toggled off, with * its links hidden. * * @since 5.4.2 */ disabledField?: string; /** * Field in data that holds the node's color. * * @default "fill" */ fillField?: string; /** * [[ColorSet]] that gives each node its color, unless the data sets one. */ colors?: ColorSet; /** * A [[PatternSet]] that series will use to apply to its nodes. * * @see {@link https://www.amcharts.com/docs/v5/concepts/colors-gradients-and-patterns/patterns/#Pattern_sets} for more info * @since 5.10.0 */ patterns?: PatternSet; /** * Animation duration in ms. */ animationDuration?: number; /** * Easing function to use for node animations. */ animationEasing?: (t: Time) => Time; } export interface IFlowNodesPrivate extends ISeriesPrivate { } export interface IFlowNodesEvents extends ISeriesEvents { } /** * Holds instances of nodes for a [[Flow]] series. */ export declare abstract class FlowNodes extends Series { static className: string; static classNames: Array; _settings: IFlowNodesSettings; _privateSettings: IFlowNodesPrivate; _dataItemSettings: IFlowNodesDataItem; _events: IFlowNodesEvents; _applyThemes(force?: boolean): boolean; /** * List of node labels; configure them all through `labels.template`. */ readonly labels: ListTemplate