123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778 |
- "use strict";
- /**
- * @fileOverview default theme
- * @author dxq613@gail.com
- */
- var Util = require('./util/common');
- var color1 = '#E8E8E8'; // color of axis-line and axis-grid
- var color2 = '#808080'; // color of axis label
- var defaultAxis = {
- label: {
- fill: color2,
- fontSize: 10
- },
- line: {
- stroke: color1,
- lineWidth: 1
- },
- grid: {
- type: 'line',
- stroke: color1,
- lineWidth: 1,
- lineDash: [2]
- },
- tickLine: null,
- labelOffset: 7.5
- };
- var Theme = {
- fontFamily: '"Helvetica Neue", "San Francisco", Helvetica, Tahoma, Arial, "PingFang SC", "Hiragino Sans GB", "Heiti SC", "Microsoft YaHei", sans-serif',
- defaultColor: '#1890FF',
- pixelRatio: 1,
- padding: 'auto',
- appendPadding: 15,
- colors: ['#1890FF', '#2FC25B', '#FACC14', '#223273', '#8543E0', '#13C2C2', '#3436C7', '#F04864'],
- shapes: {
- line: ['line', 'dash'],
- point: ['circle', 'hollowCircle']
- },
- sizes: [4, 10],
- axis: {
- common: defaultAxis,
- // common axis configuration
- bottom: Util.mix({}, defaultAxis, {
- grid: null
- }),
- left: Util.mix({}, defaultAxis, {
- line: null
- }),
- right: Util.mix({}, defaultAxis, {
- line: null
- }),
- circle: Util.mix({}, defaultAxis, {
- line: null
- }),
- radius: Util.mix({}, defaultAxis, {
- labelOffset: 4
- })
- },
- shape: {
- line: {
- lineWidth: 2,
- lineJoin: 'round',
- lineCap: 'round'
- },
- point: {
- lineWidth: 0,
- size: 3
- },
- area: {
- fillOpacity: 0.1
- }
- },
- _defaultAxis: defaultAxis
- };
- module.exports = Theme;
|