Bind graph using the DOM element instead of id

Billboard must receive the graph element directly because the chart can be
rendered while it is still detached from the document.

Closes #14970
This commit is contained in:
Eva Luadora
2026-09-02 13:57:21 +02:00
parent bbbea59530
commit b096ea372d
+1 -2
View File
@@ -69,7 +69,6 @@
this.xfield = xfield;
this.yfields = yfields;
this.el = jQuery('<div/>');
this.el.uniqueId();
},
update_data: function(group) {
var data = {};
@@ -171,7 +170,7 @@
_bb_config: function(data) {
var bb_config = {};
bb_config.bindto = '#' + this.el.attr('id');
bb_config.bindto = this.el.get(0);
bb_config.data = data;
bb_config.data.type = this._chart_type;
bb_config.data.x = 'labels';