mirror of
https://github.com/getrebuild/rebuild.git
synced 2025-09-09 08:05:38 +08:00
Update charts.js
This commit is contained in:
parent
7ec48fc54f
commit
18e347f2bd
1 changed files with 6 additions and 1 deletions
|
@ -528,9 +528,14 @@ const reOptionMutliYAxis = function (option) {
|
|||
}
|
||||
|
||||
const renderEChart = function (option, $target) {
|
||||
const c = echarts.init(document.getElementById($target), 'light', {
|
||||
$target = document.getElementById($target)
|
||||
const c = echarts.init($target, 'light', {
|
||||
renderer: navigator.userAgent.match(/(iPhone|iPod|Android|ios|SymbianOS)/i) ? 'svg' : 'canvas',
|
||||
})
|
||||
// v4.2 禁用右键
|
||||
$target.addEventListener('contextmenu', function (e) {
|
||||
e.preventDefault()
|
||||
})
|
||||
if (rb.env === 'dev') console.log(option)
|
||||
c.setOption(option)
|
||||
return c
|
||||
|
|
Loading…
Add table
Reference in a new issue