Quellcode durchsuchen

Merge pull request #241 from frappe/disable-animate

feat: allow disabling animations using 'animate' option
tags/1.3.0
Shivam Mishra vor 5 Jahren
committed by GitHub
Ursprung
Commit
96618fa8e2
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden GPG-Schlüssel-ID: 4AEE18F83AFDEB23
1 geänderte Dateien mit 2 neuen und 2 gelöschten Zeilen
  1. +2
    -2
      src/js/charts/BaseChart.js

+ 2
- 2
src/js/charts/BaseChart.js Datei anzeigen

@@ -32,7 +32,7 @@ export default class BaseChart {
showTooltip: 1, // calculate showTooltip: 1, // calculate
showLegend: 1, // calculate showLegend: 1, // calculate
isNavigable: options.isNavigable || 0, isNavigable: options.isNavigable || 0,
animate: 1,
animate: (typeof options.animate !== 'undefined') ? options.animate : 1,
truncateLegends: options.truncateLegends || 0 truncateLegends: options.truncateLegends || 0
}; };


@@ -225,7 +225,7 @@ export default class BaseChart {
} }
this.data = this.prepareData(data); this.data = this.prepareData(data);
this.calc(); // builds state this.calc(); // builds state
this.render();
this.render(this.components, this.config.animate);
} }


render(components=this.components, animate=true) { render(components=this.components, animate=true) {


Laden…
Abbrechen
Speichern