SliderTimelineModel.js 6.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156
  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 { __extends } from "tslib";
  41. import TimelineModel from './TimelineModel.js';
  42. import { DataFormatMixin } from '../../model/mixin/dataFormat.js';
  43. import { mixin } from 'zrender/lib/core/util.js';
  44. import { inheritDefaultOption } from '../../util/component.js';
  45. import tokens from '../../visual/tokens.js';
  46. var SliderTimelineModel = /** @class */function (_super) {
  47. __extends(SliderTimelineModel, _super);
  48. function SliderTimelineModel() {
  49. var _this = _super !== null && _super.apply(this, arguments) || this;
  50. _this.type = SliderTimelineModel.type;
  51. return _this;
  52. }
  53. SliderTimelineModel.type = 'timeline.slider';
  54. /**
  55. * @protected
  56. */
  57. SliderTimelineModel.defaultOption = inheritDefaultOption(TimelineModel.defaultOption, {
  58. backgroundColor: 'rgba(0,0,0,0)',
  59. borderColor: tokens.color.border,
  60. borderWidth: 0,
  61. orient: 'horizontal',
  62. inverse: false,
  63. tooltip: {
  64. trigger: 'item' // data item may also have tootip attr.
  65. },
  66. symbol: 'circle',
  67. symbolSize: 12,
  68. lineStyle: {
  69. show: true,
  70. width: 2,
  71. color: tokens.color.accent10
  72. },
  73. label: {
  74. position: 'auto',
  75. // When using number, label position is not
  76. // restricted by viewRect.
  77. // positive: right/bottom, negative: left/top
  78. show: true,
  79. interval: 'auto',
  80. rotate: 0,
  81. // formatter: null,
  82. // 其余属性默认使用全局文本样式,详见TEXTSTYLE
  83. color: tokens.color.tertiary
  84. },
  85. itemStyle: {
  86. color: tokens.color.accent20,
  87. borderWidth: 0
  88. },
  89. checkpointStyle: {
  90. symbol: 'circle',
  91. symbolSize: 15,
  92. color: tokens.color.accent50,
  93. borderColor: tokens.color.accent50,
  94. borderWidth: 0,
  95. shadowBlur: 0,
  96. shadowOffsetX: 0,
  97. shadowOffsetY: 0,
  98. shadowColor: 'rgba(0, 0, 0, 0)',
  99. // borderColor: 'rgba(194,53,49, 0.5)',
  100. animation: true,
  101. animationDuration: 300,
  102. animationEasing: 'quinticInOut'
  103. },
  104. controlStyle: {
  105. show: true,
  106. showPlayBtn: true,
  107. showPrevBtn: true,
  108. showNextBtn: true,
  109. itemSize: 24,
  110. itemGap: 12,
  111. position: 'left',
  112. playIcon: 'path://M15 0C23.2843 0 30 6.71573 30 15C30 23.2843 23.2843 30 15 30C6.71573 30 0 23.2843 0 15C0 6.71573 6.71573 0 15 0ZM15 3C8.37258 3 3 8.37258 3 15C3 21.6274 8.37258 27 15 27C21.6274 27 27 21.6274 27 15C27 8.37258 21.6274 3 15 3ZM11.5 10.6699C11.5 9.90014 12.3333 9.41887 13 9.80371L20.5 14.1338C21.1667 14.5187 21.1667 15.4813 20.5 15.8662L13 20.1963C12.3333 20.5811 11.5 20.0999 11.5 19.3301V10.6699Z',
  113. stopIcon: 'path://M15 0C23.2843 0 30 6.71573 30 15C30 23.2843 23.2843 30 15 30C6.71573 30 0 23.2843 0 15C0 6.71573 6.71573 0 15 0ZM15 3C8.37258 3 3 8.37258 3 15C3 21.6274 8.37258 27 15 27C21.6274 27 27 21.6274 27 15C27 8.37258 21.6274 3 15 3ZM11.5 10C12.3284 10 13 10.6716 13 11.5V18.5C13 19.3284 12.3284 20 11.5 20C10.6716 20 10 19.3284 10 18.5V11.5C10 10.6716 10.6716 10 11.5 10ZM18.5 10C19.3284 10 20 10.6716 20 11.5V18.5C20 19.3284 19.3284 20 18.5 20C17.6716 20 17 19.3284 17 18.5V11.5C17 10.6716 17.6716 10 18.5 10Z',
  114. // eslint-disable-next-line max-len
  115. nextIcon: 'path://M0.838834 18.7383C0.253048 18.1525 0.253048 17.2028 0.838834 16.617L7.55635 9.89949L0.838834 3.18198C0.253048 2.59619 0.253048 1.64645 0.838834 1.06066C1.42462 0.474874 2.37437 0.474874 2.96015 1.06066L10.7383 8.83883L10.8412 8.95277C11.2897 9.50267 11.2897 10.2963 10.8412 10.8462L10.7383 10.9602L2.96015 18.7383C2.37437 19.3241 1.42462 19.3241 0.838834 18.7383Z',
  116. // eslint-disable-next-line max-len
  117. prevIcon: 'path://M10.9602 1.06066C11.5459 1.64645 11.5459 2.59619 10.9602 3.18198L4.24264 9.89949L10.9602 16.617C11.5459 17.2028 11.5459 18.1525 10.9602 18.7383C10.3744 19.3241 9.42462 19.3241 8.83883 18.7383L1.06066 10.9602L0.957771 10.8462C0.509245 10.2963 0.509245 9.50267 0.957771 8.95277L1.06066 8.83883L8.83883 1.06066C9.42462 0.474874 10.3744 0.474874 10.9602 1.06066Z',
  118. prevBtnSize: 18,
  119. nextBtnSize: 18,
  120. color: tokens.color.accent50,
  121. borderColor: tokens.color.accent50,
  122. borderWidth: 0
  123. },
  124. emphasis: {
  125. label: {
  126. show: true,
  127. // 其余属性默认使用全局文本样式,详见TEXTSTYLE
  128. color: tokens.color.accent60
  129. },
  130. itemStyle: {
  131. color: tokens.color.accent60,
  132. borderColor: tokens.color.accent60
  133. },
  134. controlStyle: {
  135. color: tokens.color.accent70,
  136. borderColor: tokens.color.accent70
  137. }
  138. },
  139. progress: {
  140. lineStyle: {
  141. color: tokens.color.accent30
  142. },
  143. itemStyle: {
  144. color: tokens.color.accent40
  145. }
  146. },
  147. data: []
  148. });
  149. return SliderTimelineModel;
  150. }(TimelineModel);
  151. mixin(SliderTimelineModel, DataFormatMixin.prototype);
  152. export default SliderTimelineModel;