UNPKG

@progress/kendo-angular-charts

Version:

Kendo UI Charts for Angular - A comprehensive package for creating beautiful and interactive data visualization. Every chart type, stock charts, and sparklines are included.

79 lines (78 loc) 3.11 kB
/**----------------------------------------------------------------------------------------- * Copyright © 2024 Progress Software Corporation. All rights reserved. * Licensed under commercial license. See LICENSE.md in the project root for more information *-------------------------------------------------------------------------------------------*/ import { TemplateRef } from '@angular/core'; import * as i0 from "@angular/core"; /** * A directive that selects a [template](link:site.data.urls.angular['templatesyntax']) * within the `<kendo-sankey-tooltip>` component for the * [links tooltip](slug:tooltip_sankey#toc-specifying-a-link-tooltip-template). * The following context fields are frequently utilized: * - `let-source="source"`&mdash;The link source data item.. * - `let-target="target"`&mdash;The link target data item. * - `let-value="value"`&mdash;The link value. * For the full list of available fields, refer to the [`SankeyLinkTooltipTemplateContext`](slug:api_charts_sankeylinktooltiptemplatecontext). * * @example * ```ts * import { Component } from '@angular/core'; * * _@Component({ * selector: 'my-app', * template: ` * <kendo-chart> * <kendo-chart-tooltip> * <ng-template kendoChartSeriesTooltipTemplate let-value="value"> * Value is {{value}} * </ng-template> * </kendo-chart-tooltip> * <kendo-chart-series> * <kendo-chart-series-item [data]="[1, 2, 3]"> * </kendo-chart-series-item> * </kendo-chart-series> * </kendo-chart> * ` * }) * class AppComponent { * } * * import { Component } from '@angular/core'; * import { SankeyData } from '@progress/kendo-angular-charts'; * * _@Component({ * selector: 'my-app', * template: ` * <kendo-sankey [data]="data"> * <kendo-sankey-tooltip [followPointer]="true"> * <ng-template kendoSankeyLinkTooltipTemplate let-source="source" let-target="target" let-value="value"> * {{ source.label?.text }} - {{ target.label?.text }}: {{ value }} * </ng-template> * </kendo-sankey-tooltip> * </kendo-sankey> * `, * }) * export class AppComponent { * public data: SankeyData = { * nodes: [ * { id: 1, label: { text: 'Linux' } }, * { id: 0, label: { text: 'iOS'} }, * { id: 2, label: { text: 'Mobile' } }, * { id: 3, label: { text: 'Desktop' } }, * ], * links: [ * { sourceId: 0, targetId: 2, value: 1 }, * { sourceId: 1, targetId: 2, value: 2 }, * { sourceId: 1, targetId: 3, value: 3 }, * ], * }; * } * * ``` */ export declare class SankeyLinkTooltipTemplateDirective { templateRef: TemplateRef<any>; constructor(templateRef: TemplateRef<any>); static ɵfac: i0.ɵɵFactoryDeclaration<SankeyLinkTooltipTemplateDirective, [{ optional: true; }]>; static ɵdir: i0.ɵɵDirectiveDeclaration<SankeyLinkTooltipTemplateDirective, "[kendoSankeyLinkTooltipTemplate]", never, {}, {}, never, never, true, never>; }