Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
junedchhipa committed Jun 19, 2019
2 parents bf9ef3e + 8119d7c commit d1fed90
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 5 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ Integrate easily with 3rd party frameworks
Useful links to wrappers other than the popular frameworks mentioned above
- [stencil-apexcharts](https://github.com/mikaelkaron/stencil-apexcharts) - Stencil Component for ApexCharts
- [apexcharter](https://github.com/dreamRs/apexcharter) - Htmlwidget for ApexCharts
- [apexcharts.rb](https://github.com/styd/apexcharts.rb) - Ruby wrapper for ApexCharts

## Usage
```js
Expand Down
8 changes: 6 additions & 2 deletions src/apexcharts.js
Original file line number Diff line number Diff line change
Expand Up @@ -468,9 +468,13 @@ export default class ApexCharts {
options,
redraw = false,
animate = true,
overwriteInitialConfig = false
overwriteInitialConfig = false,
updateSyncedCharts = true
) {
let charts = this.getSyncedCharts()
let charts = [this]
if (updateSyncedCharts) {
charts = this.getSyncedCharts()
}

if (this.w.globals.isExecCalled) {
// If the user called exec method, we don't want to get grouped charts as user specifically provided a chartID to update
Expand Down
10 changes: 7 additions & 3 deletions src/modules/Core.js
Original file line number Diff line number Diff line change
Expand Up @@ -1085,8 +1085,11 @@ export default class Core {
updateSourceChart()
}
}
})

w.config.chart.events.selection = (chart, e) => {
w.config.chart.events.selection = (chart, e) => {
targets.forEach((target) => {
let targetChart = ApexCharts.getChartByID(target)
let yaxis = Utils.clone(w.config.yaxis)
if (w.config.chart.brush.autoScaleYaxis) {
const scale = new Scales(targetChart)
Expand All @@ -1102,10 +1105,11 @@ export default class Core {
},
false,
false,
false,
false
)
}
})
})
}
}
}
}

0 comments on commit d1fed90

Please sign in to comment.