deno.land / x / billboardjs@3.6.0 / Chart / api / group.ts

نووسراو ببینە
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
/** * Copyright (c) 2017 ~ present NAVER Corp. * billboard.js project is licensed under the MIT license */import {isUndefined} from "../../module/util";
export default { /** * Update groups for the targets. * @function groups * @instance * @memberof Chart * @param {Array} groups This argument needs to be an Array that includes one or more Array that includes target ids to be grouped. * @returns {Array} Grouped data names array * @example * // data1 and data2 will be a new group. * chart.groups([ * ["data1", "data2"] * ]); */ groups<T = string[][]>(groups: T): T { const $$ = this.internal; const {config} = $$;
if (isUndefined(groups)) { return config.data_groups; }
config.data_groups = groups; $$.redraw();
return config.data_groups; }};
billboardjs

Version Info

Tagged at
2 years ago