globalDefault.js 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134
  1. /*
  2. * Licensed to the Apache Software Foundation (ASF) under one
  3. * or more contributor license agreements. See the NOTICE file
  4. * distributed with this work for additional information
  5. * regarding copyright ownership. The ASF licenses this file
  6. * to you under the Apache License, Version 2.0 (the
  7. * "License"); you may not use this file except in compliance
  8. * with the License. You may obtain a copy of the License at
  9. *
  10. * http://www.apache.org/licenses/LICENSE-2.0
  11. *
  12. * Unless required by applicable law or agreed to in writing,
  13. * software distributed under the License is distributed on an
  14. * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
  15. * KIND, either express or implied. See the License for the
  16. * specific language governing permissions and limitations
  17. * under the License.
  18. */
  19. /**
  20. * AUTO-GENERATED FILE. DO NOT MODIFY.
  21. */
  22. /*
  23. * Licensed to the Apache Software Foundation (ASF) under one
  24. * or more contributor license agreements. See the NOTICE file
  25. * distributed with this work for additional information
  26. * regarding copyright ownership. The ASF licenses this file
  27. * to you under the Apache License, Version 2.0 (the
  28. * "License"); you may not use this file except in compliance
  29. * with the License. You may obtain a copy of the License at
  30. *
  31. * http://www.apache.org/licenses/LICENSE-2.0
  32. *
  33. * Unless required by applicable law or agreed to in writing,
  34. * software distributed under the License is distributed on an
  35. * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
  36. * KIND, either express or implied. See the License for the
  37. * specific language governing permissions and limitations
  38. * under the License.
  39. */
  40. import { modifyHSL } from 'zrender/lib/tool/color.js';
  41. import tokens from '../visual/tokens.js';
  42. var platform = '';
  43. // Navigator not exists in node
  44. if (typeof navigator !== 'undefined') {
  45. platform = navigator.platform || '';
  46. }
  47. var decalColor = 'rgba(0, 0, 0, 0.2)';
  48. var themeColor = tokens.color.theme[0];
  49. var lightThemeColor = modifyHSL(themeColor, null, null, 0.9);
  50. export default {
  51. darkMode: 'auto',
  52. // backgroundColor: 'rgba(0,0,0,0)',
  53. colorBy: 'series',
  54. color: tokens.color.theme,
  55. gradientColor: [lightThemeColor, themeColor],
  56. aria: {
  57. decal: {
  58. decals: [{
  59. color: decalColor,
  60. dashArrayX: [1, 0],
  61. dashArrayY: [2, 5],
  62. symbolSize: 1,
  63. rotation: Math.PI / 6
  64. }, {
  65. color: decalColor,
  66. symbol: 'circle',
  67. dashArrayX: [[8, 8], [0, 8, 8, 0]],
  68. dashArrayY: [6, 0],
  69. symbolSize: 0.8
  70. }, {
  71. color: decalColor,
  72. dashArrayX: [1, 0],
  73. dashArrayY: [4, 3],
  74. rotation: -Math.PI / 4
  75. }, {
  76. color: decalColor,
  77. dashArrayX: [[6, 6], [0, 6, 6, 0]],
  78. dashArrayY: [6, 0]
  79. }, {
  80. color: decalColor,
  81. dashArrayX: [[1, 0], [1, 6]],
  82. dashArrayY: [1, 0, 6, 0],
  83. rotation: Math.PI / 4
  84. }, {
  85. color: decalColor,
  86. symbol: 'triangle',
  87. dashArrayX: [[9, 9], [0, 9, 9, 0]],
  88. dashArrayY: [7, 2],
  89. symbolSize: 0.75
  90. }]
  91. }
  92. },
  93. // If xAxis and yAxis declared, grid is created by default.
  94. // grid: {},
  95. textStyle: {
  96. // color: '#000',
  97. // decoration: 'none',
  98. // PENDING
  99. fontFamily: platform.match(/^Win/) ? 'Microsoft YaHei' : 'sans-serif',
  100. // fontFamily: 'Arial, Verdana, sans-serif',
  101. fontSize: 12,
  102. fontStyle: 'normal',
  103. fontWeight: 'normal'
  104. },
  105. // http://blogs.adobe.com/webplatform/2014/02/24/using-blend-modes-in-html-canvas/
  106. // https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/globalCompositeOperation
  107. // Default is source-over
  108. blendMode: null,
  109. stateAnimation: {
  110. duration: 300,
  111. easing: 'cubicOut'
  112. },
  113. animation: 'auto',
  114. animationDuration: 1000,
  115. animationDurationUpdate: 500,
  116. animationEasing: 'cubicInOut',
  117. animationEasingUpdate: 'cubicInOut',
  118. animationThreshold: 2000,
  119. // Configuration for progressive/incremental rendering
  120. progressiveThreshold: 3000,
  121. progressive: 400,
  122. // Threshold of if use single hover layer to optimize.
  123. // It is recommended that `hoverLayerThreshold` is equivalent to or less than
  124. // `progressiveThreshold`, otherwise hover will cause restart of progressive,
  125. // which is unexpected.
  126. // see example <echarts/test/heatmap-large.html>.
  127. hoverLayerThreshold: 3000,
  128. // See: module:echarts/scale/Time
  129. useUTC: false
  130. };