You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
548 B
17 lines
548 B
import { Chart } from './core'; |
|
|
|
Chart.prototype.category = function (i, category) { |
|
var $$ = this.internal, config = $$.config; |
|
if (arguments.length > 1) { |
|
config.axis_x_categories[i] = category; |
|
$$.redraw(); |
|
} |
|
return config.axis_x_categories[i]; |
|
}; |
|
Chart.prototype.categories = function (categories) { |
|
var $$ = this.internal, config = $$.config; |
|
if (!arguments.length) { return config.axis_x_categories; } |
|
config.axis_x_categories = categories; |
|
$$.redraw(); |
|
return config.axis_x_categories; |
|
};
|
|
|