fix:进度条添加颜色渐变

main
liu.shiyi 2 years ago
parent 9848014935
commit f513732722

@ -35,7 +35,7 @@ const setting = [
field: 'frontColor', field: 'frontColor',
// 对应options中的字段 // 对应options中的字段
optionField: 'frontColor', optionField: 'frontColor',
value: 'l(0) 0:#5F92F9 1:#5F92F9', value: 'l(0) 0:#6B74E3 1:#38BBE5',
tabName: 'custom', tabName: 'custom',
groupName: 'graph' groupName: 'graph'
}, },
@ -89,8 +89,8 @@ const option = {
percent: 0.8, percent: 0.8,
barWidthRatio: 0.3, barWidthRatio: 0.3,
backColor: 'rgba(255, 255, 255, 0)', backColor: 'rgba(255, 255, 255, 0)',
frontColor: '#4a7af4', frontColor: 'l(0) 0:#6B74E3 1:#38BBE5',
color: ['#4a7af4', 'rgba(255, 255, 255, 0)'], color: ['l(0) 0:#6B74E3 1:#38BBE5', 'rgba(255, 255, 255, 0)'],
progressStyle: { progressStyle: {
r: 10, r: 10,
// fill: 'red', // fill: 'red',

@ -72,7 +72,7 @@ const setting = [
// 对应options中的字段 // 对应options中的字段
optionField: 'statistic.title.offsetY', optionField: 'statistic.title.offsetY',
value: -36, value: -36,
min:-100, min: -100,
tabName: 'custom', tabName: 'custom',
groupName: 'graph' groupName: 'graph'
}, },
@ -111,7 +111,7 @@ const setting = [
value: 20, value: 20,
tabName: 'custom', tabName: 'custom',
groupName: 'graph' groupName: 'graph'
}, }
// 边距 padding // 边距 padding
] ]
const data = [ const data = [

@ -42,12 +42,12 @@ const setting = [
{ {
label: '进度条颜色', label: '进度条颜色',
// 设置组件类型 // 设置组件类型
type: 'colorPicker', type: 'gradual',
// 字段 // 字段
field: 'frontColor', field: 'frontColor',
// 对应options中的字段 // 对应options中的字段
optionField: 'frontColor', optionField: 'frontColor',
value: '#4a7af4', value: 'l(0) 0:#6B74E3 1:#38BBE5',
tabName: 'custom', tabName: 'custom',
groupName: 'graph' groupName: 'graph'
}, },
@ -87,8 +87,8 @@ const option = {
percent: 0.8, percent: 0.8,
barWidthRatio: 0.3, barWidthRatio: 0.3,
backColor: '#EEEEEE', backColor: '#EEEEEE',
frontColor: '#4391F4', frontColor: 'l(0) 0:#6B74E3 1:#38BBE5',
color: ['#4a7af4', '#fff'], color: ['l(0) 0:#6B74E3 1:#38BBE5', '#fff'],
progressStyle: { progressStyle: {
current: { current: {
style: { style: {

@ -41,12 +41,12 @@ const setting = [
{ {
label: '进度条颜色', label: '进度条颜色',
// 设置组件类型 // 设置组件类型
type: 'colorPicker', type: 'gradual',
// 字段 // 字段
field: 'color1', field: 'color1',
// 对应options中的字段 // 对应options中的字段
optionField: 'color1', optionField: 'color1',
value: 'rgba(67, 145, 244, 1)', value: 'l(0) 0:#6B74E3 1:#38BBE5',
tabName: 'custom', tabName: 'custom',
groupName: 'graph' groupName: 'graph'
}, },
@ -153,11 +153,11 @@ const option = {
// 数据将要放入到哪个字段中 // 数据将要放入到哪个字段中
dataKey: 'percent', dataKey: 'percent',
data, data,
color1: '#F4664A', color1: 'l(0) 0:#6B74E3 1:#38BBE5',
color2: '#d0d0d0', color2: '#d0d0d0',
autoFit: true, autoFit: true,
percent: 0.6, percent: 0.6,
color: ['#F4664A', '#d0d0d0'], color: ['l(0) 0:#6B74E3 1:#38BBE5', '#d0d0d0'],
innerRadius: 0.85, innerRadius: 0.85,
radius: 0.98, radius: 0.98,
statistic: { statistic: {

Loading…
Cancel
Save