zz-chart
Advanced tools
Comparing version 0.1.1-beta.31 to 0.1.1-beta.32
@@ -60,3 +60,4 @@ import { get, isNumber } from 'lodash'; | ||
: Math.min(dataMin, min || 0); | ||
const maxV = Math.max(dataMax, max || 0); | ||
const defaultMax = dataMin === 0 && dataMax === 0 ? 1 : 0; | ||
const maxV = Math.max(dataMax, max || defaultMax); | ||
return [minV, maxV > 1 ? maxV + 1 : maxV]; | ||
@@ -63,0 +64,0 @@ }, |
import { StyleSheet, css } from 'aphrodite/no-important.js'; | ||
import { get, isArray, isBoolean, isElement, isFunction, isString, } from 'lodash'; | ||
import { get, isArray, isBoolean, isElement, isFunction, isNil, isString, } from 'lodash'; | ||
import placement from 'placement.js'; | ||
@@ -151,6 +151,7 @@ import { ChartEvent, } from '../types/index.js'; | ||
const name = this.handleTemplateString(String(item.name), nameFormatter, item); | ||
console.log(isNil(value), value); | ||
return `<li class="${css(styles['tooltip-list-item'])}" style="background: ${item.activated ? this.ctrl.getTheme().tooltip.activeBg : 'unset'}"> | ||
<span class="${css(symbolStyle.symbol)} ${css(symbolStyle.line)}" style="background: ${item.color};"></span> | ||
<span class="${generateName('tooltip-name')} ${css(styles['tooltip-name'])}">${name || NOT_AVAILABLE}</span> | ||
<span class="${generateName('tooltip-value')} ${css(styles['tooltip-value'])}">${value || NOT_AVAILABLE}</span> | ||
<span class="${generateName('tooltip-value')} ${css(styles['tooltip-value'])}">${isNil(value) ? NOT_AVAILABLE : value}</span> | ||
</li>`; | ||
@@ -157,0 +158,0 @@ }) |
{ | ||
"name": "zz-chart", | ||
"version": "0.1.1-beta.31", | ||
"version": "0.1.1-beta.32", | ||
"type": "module", | ||
@@ -5,0 +5,0 @@ "description": "Alauda Chart components by Alauda Frontend Team", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
848618
19682