CylinderSeries.js 5.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175
  1. /* *
  2. *
  3. * Highcharts cylinder - a 3D series
  4. *
  5. * (c) 2010-2021 Highsoft AS
  6. *
  7. * Author: Kacper Madej
  8. *
  9. * License: www.highcharts.com/license
  10. *
  11. * !!!!!!! SOURCE GETS TRANSPILED BY TYPESCRIPT. EDIT TS FILE ONLY. !!!!!!!
  12. *
  13. * */
  14. 'use strict';
  15. var __extends = (this && this.__extends) || (function () {
  16. var extendStatics = function (d, b) {
  17. extendStatics = Object.setPrototypeOf ||
  18. ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
  19. function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
  20. return extendStatics(d, b);
  21. };
  22. return function (d, b) {
  23. extendStatics(d, b);
  24. function __() { this.constructor = d; }
  25. d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
  26. };
  27. })();
  28. import CylinderPoint from './CylinderPoint.js';
  29. import SeriesRegistry from '../../Core/Series/SeriesRegistry.js';
  30. var ColumnSeries = SeriesRegistry.seriesTypes.column;
  31. import U from '../../Core/Utilities.js';
  32. var extend = U.extend, merge = U.merge;
  33. import './CylinderComposition.js';
  34. /* *
  35. *
  36. * Class
  37. *
  38. * */
  39. /**
  40. * The cylinder series type.
  41. *
  42. * @requires module:highcharts-3d
  43. * @requires module:modules/cylinder
  44. *
  45. * @private
  46. * @class
  47. * @name Highcharts.seriesTypes.cylinder
  48. *
  49. * @augments Highcharts.Series
  50. */
  51. var CylinderSeries = /** @class */ (function (_super) {
  52. __extends(CylinderSeries, _super);
  53. function CylinderSeries() {
  54. /* *
  55. *
  56. * Static Properties
  57. *
  58. * */
  59. var _this = _super !== null && _super.apply(this, arguments) || this;
  60. /* *
  61. *
  62. * Properties
  63. *
  64. * */
  65. _this.data = void 0;
  66. _this.options = void 0;
  67. _this.points = void 0;
  68. return _this;
  69. }
  70. /**
  71. * A cylinder graph is a variation of a 3d column graph. The cylinder graph
  72. * features cylindrical points.
  73. *
  74. * @sample {highcharts} highcharts/demo/cylinder/
  75. * Cylinder graph
  76. *
  77. * @extends plotOptions.column
  78. * @since 7.0.0
  79. * @product highcharts
  80. * @excluding allAreas, boostThreshold, colorAxis, compare, compareBase,
  81. * dragDrop, boostBlending
  82. * @requires modules/cylinder
  83. * @optionparent plotOptions.cylinder
  84. */
  85. CylinderSeries.defaultOptions = merge(ColumnSeries.defaultOptions);
  86. return CylinderSeries;
  87. }(ColumnSeries));
  88. extend(CylinderSeries.prototype, {
  89. pointClass: CylinderPoint
  90. });
  91. SeriesRegistry.registerSeriesType('cylinder', CylinderSeries);
  92. /* *
  93. *
  94. * Default Export
  95. *
  96. * */
  97. export default CylinderSeries;
  98. /* *
  99. *
  100. * API Options
  101. *
  102. * */
  103. /**
  104. * A `cylinder` series. If the [type](#series.cylinder.type) option is not
  105. * specified, it is inherited from [chart.type](#chart.type).
  106. *
  107. * @extends series,plotOptions.cylinder
  108. * @since 7.0.0
  109. * @product highcharts
  110. * @excluding allAreas, boostThreshold, colorAxis, compare, compareBase,
  111. * boostBlending
  112. * @requires modules/cylinder
  113. * @apioption series.cylinder
  114. */
  115. /**
  116. * An array of data points for the series. For the `cylinder` series type,
  117. * points can be given in the following ways:
  118. *
  119. * 1. An array of numerical values. In this case, the numerical values will be
  120. * interpreted as `y` options. The `x` values will be automatically
  121. * calculated, either starting at 0 and incremented by 1, or from
  122. * `pointStart` and `pointInterval` given in the series options. If the axis
  123. * has categories, these will be used. Example:
  124. * ```js
  125. * data: [0, 5, 3, 5]
  126. * ```
  127. *
  128. * 2. An array of arrays with 2 values. In this case, the values correspond to
  129. * `x,y`. If the first value is a string, it is applied as the name of the
  130. * point, and the `x` value is inferred.
  131. * ```js
  132. * data: [
  133. * [0, 0],
  134. * [1, 8],
  135. * [2, 9]
  136. * ]
  137. * ```
  138. *
  139. * 3. An array of objects with named values. The following snippet shows only a
  140. * few settings, see the complete options set below. If the total number of
  141. * data points exceeds the series'
  142. * [turboThreshold](#series.cylinder.turboThreshold), this option is not
  143. * available.
  144. *
  145. * ```js
  146. * data: [{
  147. * x: 1,
  148. * y: 2,
  149. * name: "Point2",
  150. * color: "#00FF00"
  151. * }, {
  152. * x: 1,
  153. * y: 4,
  154. * name: "Point1",
  155. * color: "#FF00FF"
  156. * }]
  157. * ```
  158. *
  159. * @sample {highcharts} highcharts/chart/reflow-true/
  160. * Numerical values
  161. * @sample {highcharts} highcharts/series/data-array-of-arrays/
  162. * Arrays of numeric x and y
  163. * @sample {highcharts} highcharts/series/data-array-of-arrays-datetime/
  164. * Arrays of datetime x and y
  165. * @sample {highcharts} highcharts/series/data-array-of-name-value/
  166. * Arrays of point.name and y
  167. * @sample {highcharts} highcharts/series/data-array-of-objects/
  168. * Config objects
  169. *
  170. * @type {Array<number|Array<(number|string),(number|null)>|null|*>}
  171. * @extends series.column.data
  172. * @product highcharts highstock
  173. * @apioption series.cylinder.data
  174. */
  175. ''; // keeps doclets above in the transpiled file