globalDefault.js 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135
  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. /* global navigator */
  46. platform = navigator.platform || '';
  47. }
  48. var decalColor = 'rgba(0, 0, 0, 0.2)';
  49. var themeColor = tokens.color.theme[0];
  50. var lightThemeColor = modifyHSL(themeColor, null, null, 0.9);
  51. export default {
  52. darkMode: 'auto',
  53. // backgroundColor: 'rgba(0,0,0,0)',
  54. colorBy: 'series',
  55. color: tokens.color.theme,
  56. gradientColor: [lightThemeColor, themeColor],
  57. aria: {
  58. decal: {
  59. decals: [{
  60. color: decalColor,
  61. dashArrayX: [1, 0],
  62. dashArrayY: [2, 5],
  63. symbolSize: 1,
  64. rotation: Math.PI / 6
  65. }, {
  66. color: decalColor,
  67. symbol: 'circle',
  68. dashArrayX: [[8, 8], [0, 8, 8, 0]],
  69. dashArrayY: [6, 0],
  70. symbolSize: 0.8
  71. }, {
  72. color: decalColor,
  73. dashArrayX: [1, 0],
  74. dashArrayY: [4, 3],
  75. rotation: -Math.PI / 4
  76. }, {
  77. color: decalColor,
  78. dashArrayX: [[6, 6], [0, 6, 6, 0]],
  79. dashArrayY: [6, 0]
  80. }, {
  81. color: decalColor,
  82. dashArrayX: [[1, 0], [1, 6]],
  83. dashArrayY: [1, 0, 6, 0],
  84. rotation: Math.PI / 4
  85. }, {
  86. color: decalColor,
  87. symbol: 'triangle',
  88. dashArrayX: [[9, 9], [0, 9, 9, 0]],
  89. dashArrayY: [7, 2],
  90. symbolSize: 0.75
  91. }]
  92. }
  93. },
  94. // If xAxis and yAxis declared, grid is created by default.
  95. // grid: {},
  96. textStyle: {
  97. // color: '#000',
  98. // decoration: 'none',
  99. // PENDING
  100. fontFamily: platform.match(/^Win/) ? 'Microsoft YaHei' : 'sans-serif',
  101. // fontFamily: 'Arial, Verdana, sans-serif',
  102. fontSize: 12,
  103. fontStyle: 'normal',
  104. fontWeight: 'normal'
  105. },
  106. // http://blogs.adobe.com/webplatform/2014/02/24/using-blend-modes-in-html-canvas/
  107. // https://developer.mozilla.org/en-US/docs/Web/API/CanvasRenderingContext2D/globalCompositeOperation
  108. // Default is source-over
  109. blendMode: null,
  110. stateAnimation: {
  111. duration: 300,
  112. easing: 'cubicOut'
  113. },
  114. animation: 'auto',
  115. animationDuration: 1000,
  116. animationDurationUpdate: 500,
  117. animationEasing: 'cubicInOut',
  118. animationEasingUpdate: 'cubicInOut',
  119. animationThreshold: 2000,
  120. // Configuration for progressive/incremental rendering
  121. progressiveThreshold: 3000,
  122. progressive: 400,
  123. // Threshold of if use single hover layer to optimize.
  124. // It is recommended that `hoverLayerThreshold` is equivalent to or less than
  125. // `progressiveThreshold`, otherwise hover will cause restart of progressive,
  126. // which is unexpected.
  127. // see example <echarts/test/heatmap-large.html>.
  128. hoverLayerThreshold: 3000,
  129. // See: module:echarts/scale/Time
  130. useUTC: false
  131. };