Merged branch with master
This commit is contained in:
commit
c8e6afca3e
7
.github/PULL_REQUEST_TEMPLATE.md
vendored
7
.github/PULL_REQUEST_TEMPLATE.md
vendored
@ -1,7 +1,14 @@
|
|||||||
|
<!-- Thank you so much for contributing! We're glad to have you onboard :) -->
|
||||||
|
<!-- Please help us understand you contribution better with these details -->
|
||||||
|
|
||||||
###### Explanation About What Code Achieves:
|
###### Explanation About What Code Achieves:
|
||||||
<!-- Please explain why this code is necessary / what it does -->
|
<!-- Please explain why this code is necessary / what it does -->
|
||||||
- Explanation
|
- Explanation
|
||||||
|
|
||||||
|
###### Screenshots/GIFs:
|
||||||
|
<!-- As this is mainly a visual lib, please include a screenshot/gif if your contribution modifies on-screen components -->
|
||||||
|
- Screenshot
|
||||||
|
|
||||||
###### Steps To Test:
|
###### Steps To Test:
|
||||||
<!-- What would someone do to be able to see the effects of your code? -->
|
<!-- What would someone do to be able to see the effects of your code? -->
|
||||||
- Steps
|
- Steps
|
||||||
|
|||||||
@ -4,7 +4,7 @@
|
|||||||
<p align="center">
|
<p align="center">
|
||||||
<p>GitHub-inspired modern, intuitive and responsive charts with zero dependencies</p>
|
<p>GitHub-inspired modern, intuitive and responsive charts with zero dependencies</p>
|
||||||
<a href="https://frappe.github.io/charts">
|
<a href="https://frappe.github.io/charts">
|
||||||
<b>Explore the Demos »</b>
|
<b>Explore Demos »</b>
|
||||||
</a>
|
</a>
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
@ -36,7 +36,7 @@
|
|||||||
</a>
|
</a>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
### Table of Contents
|
### Contents
|
||||||
* [Installation](#installation)
|
* [Installation](#installation)
|
||||||
* [Usage](#usage)
|
* [Usage](#usage)
|
||||||
* [License](#license)
|
* [License](#license)
|
||||||
@ -56,9 +56,8 @@
|
|||||||
#### Usage
|
#### Usage
|
||||||
```js
|
```js
|
||||||
const data = {
|
const data = {
|
||||||
labels: ["12am - 3am", "3am - 6pm", "6am - 9 A.M",
|
labels: ["12am-3am", "3am-6pm", "6am-9am", "9am-12am",
|
||||||
"9am - 12am", "12pm - 3pm", "3pm - 6pm",
|
"12pm-3pm", "3pm-6pm", "6pm-9pm", "9am-12am"
|
||||||
"6pm - 9pm", "9am - 12am"
|
|
||||||
],
|
],
|
||||||
datasets: [
|
datasets: [
|
||||||
{
|
{
|
||||||
|
|||||||
2
dist/frappe-charts.min.js
vendored
2
dist/frappe-charts.min.js
vendored
File diff suppressed because one or more lines are too long
2
dist/frappe-charts.min.js.map
vendored
2
dist/frappe-charts.min.js.map
vendored
File diff suppressed because one or more lines are too long
2
docs/assets/js/frappe-charts.min.js
vendored
2
docs/assets/js/frappe-charts.min.js
vendored
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -4,12 +4,10 @@ import Chart from '../charts';
|
|||||||
|
|
||||||
export default class BaseChart {
|
export default class BaseChart {
|
||||||
constructor({
|
constructor({
|
||||||
parent = "",
|
|
||||||
height = 240,
|
height = 240,
|
||||||
|
|
||||||
title = '', subtitle = '',
|
title = '', subtitle = '',
|
||||||
|
|
||||||
data = {},
|
|
||||||
format_lambdas = {},
|
format_lambdas = {},
|
||||||
|
|
||||||
summary = [],
|
summary = [],
|
||||||
@ -17,7 +15,10 @@ export default class BaseChart {
|
|||||||
is_navigable = 0,
|
is_navigable = 0,
|
||||||
has_legend = 0,
|
has_legend = 0,
|
||||||
|
|
||||||
type = '' // eslint-disable-line no-unused-vars
|
type = '', // eslint-disable-line no-unused-vars
|
||||||
|
|
||||||
|
parent,
|
||||||
|
data
|
||||||
}) {
|
}) {
|
||||||
this.raw_chart_args = arguments[0];
|
this.raw_chart_args = arguments[0];
|
||||||
|
|
||||||
@ -81,6 +82,10 @@ export default class BaseChart {
|
|||||||
}
|
}
|
||||||
|
|
||||||
setup() {
|
setup() {
|
||||||
|
if(!this.parent) {
|
||||||
|
console.error("No parent element to render on was provided.");
|
||||||
|
return;
|
||||||
|
}
|
||||||
this.bind_window_events();
|
this.bind_window_events();
|
||||||
this.refresh(true);
|
this.refresh(true);
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user