plottable 3.11.0 → 3.12.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (180) hide show
  1. package/build/src/animators/easingAnimator.d.ts +2 -2
  2. package/build/src/animators/easingAnimator.js +3 -2
  3. package/build/src/animators/index.js +2 -2
  4. package/build/src/animators/nullAnimator.js +2 -1
  5. package/build/src/axes/axis.d.ts +9 -5
  6. package/build/src/axes/axis.js +4 -3
  7. package/build/src/axes/categoryAxis.d.ts +9 -5
  8. package/build/src/axes/categoryAxis.js +13 -11
  9. package/build/src/axes/index.js +3 -3
  10. package/build/src/axes/numericAxis.d.ts +9 -5
  11. package/build/src/axes/numericAxis.js +2 -1
  12. package/build/src/axes/timeAxis.d.ts +18 -14
  13. package/build/src/axes/timeAxis.js +6 -5
  14. package/build/src/components/component.d.ts +2 -2
  15. package/build/src/components/component.js +7 -6
  16. package/build/src/components/componentContainer.js +3 -2
  17. package/build/src/components/dragBoxLayer.d.ts +4 -4
  18. package/build/src/components/dragBoxLayer.js +3 -2
  19. package/build/src/components/dragLineLayer.js +2 -1
  20. package/build/src/components/gridlines.d.ts +2 -2
  21. package/build/src/components/gridlines.js +2 -1
  22. package/build/src/components/group.js +2 -1
  23. package/build/src/components/guideLineLayer.d.ts +1 -1
  24. package/build/src/components/guideLineLayer.js +2 -1
  25. package/build/src/components/index.js +14 -14
  26. package/build/src/components/interpolatedColorLegend.d.ts +7 -3
  27. package/build/src/components/interpolatedColorLegend.js +4 -3
  28. package/build/src/components/label.js +4 -3
  29. package/build/src/components/legend.d.ts +5 -1
  30. package/build/src/components/legend.js +2 -1
  31. package/build/src/components/plotGroup.js +2 -1
  32. package/build/src/components/selectionBoxLayer.d.ts +4 -4
  33. package/build/src/components/selectionBoxLayer.js +2 -1
  34. package/build/src/components/table.d.ts +10 -6
  35. package/build/src/components/table.js +4 -3
  36. package/build/src/components/wrappedLabel.js +2 -1
  37. package/build/src/components/xDragBoxLayer.js +2 -1
  38. package/build/src/components/yDragBoxLayer.js +2 -1
  39. package/build/src/core/config.js +1 -0
  40. package/build/src/core/dataset.d.ts +5 -1
  41. package/build/src/core/dataset.js +1 -0
  42. package/build/src/core/formatters.d.ts +4 -0
  43. package/build/src/core/formatters.js +1 -0
  44. package/build/src/core/renderController.d.ts +1 -1
  45. package/build/src/core/renderController.js +2 -1
  46. package/build/src/core/renderPolicy.d.ts +4 -0
  47. package/build/src/core/renderPolicy.js +1 -0
  48. package/build/src/core/symbolFactories.d.ts +4 -0
  49. package/build/src/core/symbolFactories.js +1 -0
  50. package/build/src/core/version.d.ts +4 -0
  51. package/build/src/core/version.js +2 -1
  52. package/build/src/core/version.js.bak +1 -0
  53. package/build/src/dispatchers/dispatcher.d.ts +7 -3
  54. package/build/src/dispatchers/dispatcher.js +2 -1
  55. package/build/src/dispatchers/index.js +3 -3
  56. package/build/src/dispatchers/keyDispatcher.d.ts +2 -2
  57. package/build/src/dispatchers/keyDispatcher.js +2 -1
  58. package/build/src/dispatchers/mouseDispatcher.d.ts +1 -1
  59. package/build/src/dispatchers/mouseDispatcher.js +2 -1
  60. package/build/src/dispatchers/touchDispatcher.d.ts +1 -1
  61. package/build/src/dispatchers/touchDispatcher.js +2 -1
  62. package/build/src/drawers/arcDrawer.js +2 -1
  63. package/build/src/drawers/arcOutlineDrawer.js +2 -1
  64. package/build/src/drawers/areaDrawer.js +6 -5
  65. package/build/src/drawers/canvasBuffer.js +1 -0
  66. package/build/src/drawers/canvasDrawer.js +1 -0
  67. package/build/src/drawers/drawer.js +1 -0
  68. package/build/src/drawers/index.js +11 -10
  69. package/build/src/drawers/lineDrawer.js +4 -3
  70. package/build/src/drawers/rectangleDrawer.js +7 -5
  71. package/build/src/drawers/segmentDrawer.js +2 -1
  72. package/build/src/drawers/svgDrawer.d.ts +2 -2
  73. package/build/src/drawers/svgDrawer.js +1 -0
  74. package/build/src/drawers/symbolDrawer.js +6 -6
  75. package/build/src/index.d.ts +1 -1
  76. package/build/src/index.js +17 -14
  77. package/build/src/interactions/clickInteraction.d.ts +4 -4
  78. package/build/src/interactions/clickInteraction.js +2 -1
  79. package/build/src/interactions/dragInteraction.d.ts +4 -4
  80. package/build/src/interactions/dragInteraction.js +2 -1
  81. package/build/src/interactions/index.js +7 -6
  82. package/build/src/interactions/interaction.d.ts +2 -2
  83. package/build/src/interactions/interaction.js +1 -0
  84. package/build/src/interactions/keyInteraction.d.ts +2 -2
  85. package/build/src/interactions/keyInteraction.js +2 -1
  86. package/build/src/interactions/panZoomConstraints.js +1 -0
  87. package/build/src/interactions/panZoomInteraction.d.ts +13 -9
  88. package/build/src/interactions/panZoomInteraction.js +4 -3
  89. package/build/src/interactions/pointerInteraction.d.ts +3 -3
  90. package/build/src/interactions/pointerInteraction.js +2 -1
  91. package/build/src/memoize/index.js +5 -4
  92. package/build/src/memoize/memThunk.js +2 -1
  93. package/build/src/memoize/memoize.d.ts +5 -0
  94. package/build/src/memoize/memoize.js +2 -1
  95. package/build/src/memoize/memoizeProjectors.js +3 -2
  96. package/build/src/memoize/signature.d.ts +14 -0
  97. package/build/src/memoize/signature.js +4 -3
  98. package/build/src/plots/areaPlot.d.ts +9 -5
  99. package/build/src/plots/areaPlot.js +4 -3
  100. package/build/src/plots/barPlot.d.ts +16 -22
  101. package/build/src/plots/barPlot.js +6 -5
  102. package/build/src/plots/clusteredBarPlot.d.ts +3 -5
  103. package/build/src/plots/clusteredBarPlot.js +2 -1
  104. package/build/src/plots/commons.js +1 -0
  105. package/build/src/plots/deferredRenderer.d.ts +1 -1
  106. package/build/src/plots/deferredRenderer.js +1 -0
  107. package/build/src/plots/index.js +12 -12
  108. package/build/src/plots/linePlot.d.ts +6 -6
  109. package/build/src/plots/linePlot.js +5 -4
  110. package/build/src/plots/piePlot.d.ts +9 -5
  111. package/build/src/plots/piePlot.js +3 -2
  112. package/build/src/plots/plot.d.ts +5 -5
  113. package/build/src/plots/plot.js +7 -6
  114. package/build/src/plots/rectanglePlot.d.ts +10 -6
  115. package/build/src/plots/rectanglePlot.js +2 -1
  116. package/build/src/plots/scatterPlot.d.ts +8 -9
  117. package/build/src/plots/scatterPlot.js +3 -2
  118. package/build/src/plots/segmentPlot.d.ts +7 -3
  119. package/build/src/plots/segmentPlot.js +3 -2
  120. package/build/src/plots/stackedAreaPlot.d.ts +6 -2
  121. package/build/src/plots/stackedAreaPlot.js +4 -3
  122. package/build/src/plots/stackedBarPlot.d.ts +5 -4
  123. package/build/src/plots/stackedBarPlot.js +5 -4
  124. package/build/src/plots/waterfallPlot.d.ts +4 -6
  125. package/build/src/plots/waterfallPlot.js +2 -1
  126. package/build/src/plots/xyPlot.d.ts +5 -5
  127. package/build/src/plots/xyPlot.js +2 -1
  128. package/build/src/scales/categoryScale.d.ts +7 -3
  129. package/build/src/scales/categoryScale.js +3 -2
  130. package/build/src/scales/colorScale.d.ts +5 -1
  131. package/build/src/scales/colorScale.js +2 -1
  132. package/build/src/scales/index.d.ts +1 -1
  133. package/build/src/scales/index.js +8 -7
  134. package/build/src/scales/interpolatedColorScale.d.ts +7 -3
  135. package/build/src/scales/interpolatedColorScale.js +5 -4
  136. package/build/src/scales/linearScale.d.ts +4 -0
  137. package/build/src/scales/linearScale.js +2 -1
  138. package/build/src/scales/logScale.d.ts +4 -0
  139. package/build/src/scales/logScale.js +2 -1
  140. package/build/src/scales/modifiedLogScale.d.ts +8 -4
  141. package/build/src/scales/modifiedLogScale.js +2 -1
  142. package/build/src/scales/quantitativeScale.d.ts +5 -1
  143. package/build/src/scales/quantitativeScale.js +3 -2
  144. package/build/src/scales/scale.d.ts +4 -0
  145. package/build/src/scales/scale.js +1 -0
  146. package/build/src/scales/tickGenerators.js +1 -0
  147. package/build/src/scales/timeScale.js +2 -1
  148. package/build/src/utils/addD3SelectionMulti.d.ts +8 -0
  149. package/build/src/utils/arrayUtils.d.ts +4 -0
  150. package/build/src/utils/arrayUtils.js +1 -0
  151. package/build/src/utils/bucket.js +1 -0
  152. package/build/src/utils/callbackSet.js +2 -1
  153. package/build/src/utils/coerceD3.js +1 -0
  154. package/build/src/utils/colorUtils.d.ts +4 -0
  155. package/build/src/utils/colorUtils.js +1 -0
  156. package/build/src/utils/domUtils.d.ts +3 -10
  157. package/build/src/utils/domUtils.js +1 -0
  158. package/build/src/utils/entityStore.js +1 -0
  159. package/build/src/utils/index.d.ts +1 -1
  160. package/build/src/utils/index.js +9 -8
  161. package/build/src/utils/makeEnum.js +1 -0
  162. package/build/src/utils/map.d.ts +4 -0
  163. package/build/src/utils/map.js +1 -0
  164. package/build/src/utils/mathUtils.d.ts +4 -0
  165. package/build/src/utils/mathUtils.js +3 -2
  166. package/build/src/utils/objectUtils.js +1 -0
  167. package/build/src/utils/rTree.d.ts +1 -1
  168. package/build/src/utils/rTree.js +1 -0
  169. package/build/src/utils/rTreeSplitStrategies.d.ts +2 -2
  170. package/build/src/utils/rTreeSplitStrategies.js +1 -0
  171. package/build/src/utils/set.js +1 -0
  172. package/build/src/utils/stackingUtils.d.ts +5 -1
  173. package/build/src/utils/stackingUtils.js +6 -5
  174. package/build/src/utils/transformAwareTranslator.d.ts +4 -0
  175. package/build/src/utils/transformAwareTranslator.js +1 -0
  176. package/build/src/utils/windowUtils.d.ts +4 -0
  177. package/build/src/utils/windowUtils.js +1 -0
  178. package/package.json +6 -5
  179. package/plottable.js +40761 -29021
  180. package/plottable.js.map +1 -1
@@ -26,7 +26,7 @@ export declare class GuideLineLayer<D> extends Component {
26
26
  fixedHeight(): boolean;
27
27
  computeLayout(origin?: Point, availableWidth?: number, availableHeight?: number): this;
28
28
  renderImmediately(): this;
29
- private _syncPixelPositionAndValue();
29
+ private _syncPixelPositionAndValue;
30
30
  protected _setPixelPositionWithoutChangingMode(pixelPosition: number): void;
31
31
  /**
32
32
  * Gets the QuantitativeScale on the GuideLineLayer.
@@ -4,6 +4,7 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.GuideLineLayer = void 0;
7
8
  var tslib_1 = require("tslib");
8
9
  var Utils = require("../utils");
9
10
  var component_1 = require("./component");
@@ -13,7 +14,7 @@ var PropertyMode;
13
14
  PropertyMode[PropertyMode["PIXEL"] = 1] = "PIXEL";
14
15
  })(PropertyMode || (PropertyMode = {}));
15
16
  var GuideLineLayer = /** @class */ (function (_super) {
16
- tslib_1.__extends(GuideLineLayer, _super);
17
+ (0, tslib_1.__extends)(GuideLineLayer, _super);
17
18
  function GuideLineLayer(orientation) {
18
19
  var _this = _super.call(this) || this;
19
20
  _this._mode = PropertyMode.VALUE;
@@ -5,17 +5,17 @@
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
7
  var tslib_1 = require("tslib");
8
- tslib_1.__exportStar(require("./dragBoxLayer"), exports);
9
- tslib_1.__exportStar(require("./dragLineLayer"), exports);
10
- tslib_1.__exportStar(require("./gridlines"), exports);
11
- tslib_1.__exportStar(require("./group"), exports);
12
- tslib_1.__exportStar(require("./guideLineLayer"), exports);
13
- tslib_1.__exportStar(require("./interpolatedColorLegend"), exports);
14
- tslib_1.__exportStar(require("./label"), exports);
15
- tslib_1.__exportStar(require("./legend"), exports);
16
- tslib_1.__exportStar(require("./plotGroup"), exports);
17
- tslib_1.__exportStar(require("./selectionBoxLayer"), exports);
18
- tslib_1.__exportStar(require("./table"), exports);
19
- tslib_1.__exportStar(require("./wrappedLabel"), exports);
20
- tslib_1.__exportStar(require("./xDragBoxLayer"), exports);
21
- tslib_1.__exportStar(require("./yDragBoxLayer"), exports);
8
+ (0, tslib_1.__exportStar)(require("./dragBoxLayer"), exports);
9
+ (0, tslib_1.__exportStar)(require("./dragLineLayer"), exports);
10
+ (0, tslib_1.__exportStar)(require("./gridlines"), exports);
11
+ (0, tslib_1.__exportStar)(require("./group"), exports);
12
+ (0, tslib_1.__exportStar)(require("./guideLineLayer"), exports);
13
+ (0, tslib_1.__exportStar)(require("./interpolatedColorLegend"), exports);
14
+ (0, tslib_1.__exportStar)(require("./label"), exports);
15
+ (0, tslib_1.__exportStar)(require("./legend"), exports);
16
+ (0, tslib_1.__exportStar)(require("./plotGroup"), exports);
17
+ (0, tslib_1.__exportStar)(require("./selectionBoxLayer"), exports);
18
+ (0, tslib_1.__exportStar)(require("./table"), exports);
19
+ (0, tslib_1.__exportStar)(require("./wrappedLabel"), exports);
20
+ (0, tslib_1.__exportStar)(require("./xDragBoxLayer"), exports);
21
+ (0, tslib_1.__exportStar)(require("./yDragBoxLayer"), exports);
@@ -1,3 +1,7 @@
1
+ /**
2
+ * Copyright 2014-present Palantir Technologies
3
+ * @license MIT
4
+ */
1
5
  import { Formatter } from "../core/formatters";
2
6
  import { SpaceRequest } from "../core/interfaces";
3
7
  import * as Scales from "../scales";
@@ -57,7 +61,7 @@ export declare class InterpolatedColorLegend extends Component {
57
61
  * @returns {InterpolatedColorLegend} The calling InterpolatedColorLegend.
58
62
  */
59
63
  expands(expands: boolean): this;
60
- private static _ensureOrientation(orientation);
64
+ private static _ensureOrientation;
61
65
  /**
62
66
  * Gets the orientation.
63
67
  */
@@ -71,9 +75,9 @@ export declare class InterpolatedColorLegend extends Component {
71
75
  orientation(orientation: string): this;
72
76
  fixedWidth(): boolean;
73
77
  fixedHeight(): boolean;
74
- private _generateTicks(numSwatches?);
78
+ private _generateTicks;
75
79
  protected _setup(): void;
76
80
  requestedSpace(offeredWidth: number, offeredHeight: number): SpaceRequest;
77
- private _isVertical();
81
+ private _isVertical;
78
82
  renderImmediately(): this;
79
83
  }
@@ -4,6 +4,7 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.InterpolatedColorLegend = void 0;
7
8
  var tslib_1 = require("tslib");
8
9
  var Typesettable = require("typesettable");
9
10
  var Configs = require("../core/config");
@@ -11,7 +12,7 @@ var Formatters = require("../core/formatters");
11
12
  var Utils = require("../utils");
12
13
  var component_1 = require("./component");
13
14
  var InterpolatedColorLegend = /** @class */ (function (_super) {
14
- tslib_1.__extends(InterpolatedColorLegend, _super);
15
+ (0, tslib_1.__extends)(InterpolatedColorLegend, _super);
15
16
  /**
16
17
  * Creates an InterpolatedColorLegend.
17
18
  *
@@ -186,7 +187,7 @@ var InterpolatedColorLegend = /** @class */ (function (_super) {
186
187
  lowerWriteOptions.xAlign = "right";
187
188
  lowerLabelShift.x = -(padding + swatchWidth + textPadding);
188
189
  }
189
- else {
190
+ else { // right
190
191
  swatchX = function (d, i) { return padding; };
191
192
  upperWriteOptions.xAlign = "left";
192
193
  upperLabelShift.x = padding + swatchWidth + textPadding;
@@ -196,7 +197,7 @@ var InterpolatedColorLegend = /** @class */ (function (_super) {
196
197
  boundingBoxAttr["width"] = swatchWidth;
197
198
  boundingBoxAttr["height"] = numSwatches * swatchHeight;
198
199
  }
199
- else {
200
+ else { // horizontal
200
201
  padding = Math.max(textPadding, (this.height() - textHeight) / 2);
201
202
  numSwatches = Math.max(Math.floor(this.width() - textPadding * 4 - text0Width - text1Width), 0);
202
203
  swatchWidth = 1;
@@ -4,11 +4,12 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.AxisLabel = exports.TitleLabel = exports.Label = void 0;
7
8
  var tslib_1 = require("tslib");
8
9
  var Typesettable = require("typesettable");
9
10
  var component_1 = require("./component");
10
11
  var Label = /** @class */ (function (_super) {
11
- tslib_1.__extends(Label, _super);
12
+ (0, tslib_1.__extends)(Label, _super);
12
13
  /**
13
14
  * A Label is a Component that displays a single line of text.
14
15
  *
@@ -129,7 +130,7 @@ var Label = /** @class */ (function (_super) {
129
130
  }(component_1.Component));
130
131
  exports.Label = Label;
131
132
  var TitleLabel = /** @class */ (function (_super) {
132
- tslib_1.__extends(TitleLabel, _super);
133
+ (0, tslib_1.__extends)(TitleLabel, _super);
133
134
  /**
134
135
  * @constructor
135
136
  * @param {string} [text]
@@ -145,7 +146,7 @@ var TitleLabel = /** @class */ (function (_super) {
145
146
  }(Label));
146
147
  exports.TitleLabel = TitleLabel;
147
148
  var AxisLabel = /** @class */ (function (_super) {
148
- tslib_1.__extends(AxisLabel, _super);
149
+ (0, tslib_1.__extends)(AxisLabel, _super);
149
150
  /**
150
151
  * @constructor
151
152
  * @param {string} [text]
@@ -1,3 +1,7 @@
1
+ /**
2
+ * Copyright 2014-present Palantir Technologies
3
+ * @license MIT
4
+ */
1
5
  import { Formatter } from "../core/formatters";
2
6
  import { IEntity, Point, SpaceRequest } from "../core/interfaces";
3
7
  import { SymbolFactory } from "../core/symbolFactories";
@@ -119,7 +123,7 @@ export declare class Legend extends Component {
119
123
  */
120
124
  colorScale(colorScale: Scales.Color): this;
121
125
  destroy(): void;
122
- private _buildLegendTable(width, height);
126
+ private _buildLegendTable;
123
127
  requestedSpace(offeredWidth: number, offeredHeight: number): SpaceRequest;
124
128
  /**
125
129
  * Gets the Entities (representing Legend entries) at a particular point.
@@ -4,6 +4,7 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.Legend = void 0;
7
8
  var tslib_1 = require("tslib");
8
9
  var d3 = require("d3");
9
10
  var Typesettable = require("typesettable");
@@ -179,7 +180,7 @@ var LegendTable = /** @class */ (function () {
179
180
  return LegendTable;
180
181
  }());
181
182
  var Legend = /** @class */ (function (_super) {
182
- tslib_1.__extends(Legend, _super);
183
+ (0, tslib_1.__extends)(Legend, _super);
183
184
  /**
184
185
  * The Legend consists of a series of entries, each with a color and label taken from the Color Scale.
185
186
  *
@@ -4,12 +4,13 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.PlotGroup = void 0;
7
8
  var tslib_1 = require("tslib");
8
9
  var plot_1 = require("../plots/plot");
9
10
  var Utils = require("../utils");
10
11
  var group_1 = require("./group");
11
12
  var PlotGroup = /** @class */ (function (_super) {
12
- tslib_1.__extends(PlotGroup, _super);
13
+ (0, tslib_1.__extends)(PlotGroup, _super);
13
14
  function PlotGroup() {
14
15
  return _super !== null && _super.apply(this, arguments) || this;
15
16
  }
@@ -7,7 +7,7 @@ import { QuantitativeScale } from "../scales/quantitativeScale";
7
7
  import { Component } from "./component";
8
8
  export declare enum PropertyMode {
9
9
  VALUE = 0,
10
- PIXEL = 1,
10
+ PIXEL = 1
11
11
  }
12
12
  export declare class SelectionBoxLayer extends Component {
13
13
  protected _box: SimpleSelection<void>;
@@ -39,7 +39,7 @@ export declare class SelectionBoxLayer extends Component {
39
39
  */
40
40
  bounds(newBounds: Bounds): this;
41
41
  protected _setBounds(newBounds: Bounds): void;
42
- private _getBounds();
42
+ private _getBounds;
43
43
  renderImmediately(): this;
44
44
  /**
45
45
  * Gets whether the box is being shown.
@@ -96,7 +96,7 @@ export declare class SelectionBoxLayer extends Component {
96
96
  xExtent(xExtent: (number | {
97
97
  valueOf(): number;
98
98
  })[]): this;
99
- private _getXExtent();
99
+ private _getXExtent;
100
100
  protected _setXExtent(xExtent: (number | {
101
101
  valueOf(): number;
102
102
  })[]): void;
@@ -114,7 +114,7 @@ export declare class SelectionBoxLayer extends Component {
114
114
  yExtent(yExtent: (number | {
115
115
  valueOf(): number;
116
116
  })[]): this;
117
- private _getYExtent();
117
+ private _getYExtent;
118
118
  protected _setYExtent(yExtent: (number | {
119
119
  valueOf(): number;
120
120
  })[]): void;
@@ -4,6 +4,7 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.SelectionBoxLayer = exports.PropertyMode = void 0;
7
8
  var tslib_1 = require("tslib");
8
9
  var Utils = require("../utils");
9
10
  var component_1 = require("./component");
@@ -13,7 +14,7 @@ var PropertyMode;
13
14
  PropertyMode[PropertyMode["PIXEL"] = 1] = "PIXEL";
14
15
  })(PropertyMode = exports.PropertyMode || (exports.PropertyMode = {}));
15
16
  var SelectionBoxLayer = /** @class */ (function (_super) {
16
- tslib_1.__extends(SelectionBoxLayer, _super);
17
+ (0, tslib_1.__extends)(SelectionBoxLayer, _super);
17
18
  function SelectionBoxLayer() {
18
19
  var _this = _super.call(this) || this;
19
20
  _this._boxVisible = false;
@@ -1,3 +1,7 @@
1
+ /**
2
+ * Copyright 2014-present Palantir Technologies
3
+ * @license MIT
4
+ */
1
5
  import { Point, SpaceRequest } from "../core/interfaces";
2
6
  import { Component } from "./component";
3
7
  import { ComponentContainer } from "./componentContainer";
@@ -53,8 +57,8 @@ export declare class Table extends ComponentContainer {
53
57
  */
54
58
  add(component: Component, row: number, col: number): this;
55
59
  protected _remove(component: Component): boolean;
56
- private _iterateLayout(availableWidth, availableHeight, isFinalOffer?);
57
- private _determineGuarantees(offeredWidths, offeredHeights, isFinalOffer?);
60
+ private _iterateLayout;
61
+ private _determineGuarantees;
58
62
  requestedSpace(offeredWidth: number, offeredHeight: number): SpaceRequest;
59
63
  computeLayout(origin?: Point, availableWidth?: number, availableHeight?: number): this;
60
64
  /**
@@ -130,8 +134,8 @@ export declare class Table extends ComponentContainer {
130
134
  columnWeight(index: number, weight: number): this;
131
135
  fixedWidth(): boolean;
132
136
  fixedHeight(): boolean;
133
- private _padTableToSize(nRows, nCols);
134
- private static _calcComponentWeights(setWeights, componentGroups, fixityAccessor);
135
- private static _calcProportionalSpace(weights, freeSpace);
136
- private static _fixedSpace(componentGroup, fixityAccessor);
137
+ private _padTableToSize;
138
+ private static _calcComponentWeights;
139
+ private static _calcProportionalSpace;
140
+ private static _fixedSpace;
137
141
  }
@@ -4,12 +4,13 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.Table = void 0;
7
8
  var tslib_1 = require("tslib");
8
9
  var d3 = require("d3");
9
10
  var Utils = require("../utils");
10
11
  var componentContainer_1 = require("./componentContainer");
11
12
  var Table = /** @class */ (function (_super) {
12
- tslib_1.__extends(Table, _super);
13
+ (0, tslib_1.__extends)(Table, _super);
13
14
  /**
14
15
  * A Table combines Components in the form of a grid. A
15
16
  * common case is combining a y-axis, x-axis, and the plotted data via
@@ -179,11 +180,11 @@ var Table = /** @class */ (function (_super) {
179
180
  freeWidth = availableWidthAfterPadding - d3.sum(guarantees.guaranteedWidths);
180
181
  freeHeight = availableHeightAfterPadding - d3.sum(guarantees.guaranteedHeights);
181
182
  var xWeights = void 0;
182
- if (wantsWidth) {
183
+ if (wantsWidth) { // If something wants width, divide free space between components that want more width
183
184
  xWeights = guarantees.wantsWidthArr.map(function (x) { return x ? 0.1 : 0; });
184
185
  xWeights = Utils.Array.add(xWeights, colWeights);
185
186
  }
186
- else {
187
+ else { // Otherwise, divide free space according to the weights
187
188
  xWeights = colWeights;
188
189
  }
189
190
  var yWeights = void 0;
@@ -4,11 +4,12 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.WrappedLabel = void 0;
7
8
  var tslib_1 = require("tslib");
8
9
  var label_1 = require("./label");
9
10
  var DEFAULT_MAX_LINES = 2;
10
11
  var WrappedLabel = /** @class */ (function (_super) {
11
- tslib_1.__extends(WrappedLabel, _super);
12
+ (0, tslib_1.__extends)(WrappedLabel, _super);
12
13
  function WrappedLabel() {
13
14
  var _this = _super !== null && _super.apply(this, arguments) || this;
14
15
  _this._maxLines = DEFAULT_MAX_LINES;
@@ -4,10 +4,11 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.XDragBoxLayer = void 0;
7
8
  var tslib_1 = require("tslib");
8
9
  var dragBoxLayer_1 = require("./dragBoxLayer");
9
10
  var XDragBoxLayer = /** @class */ (function (_super) {
10
- tslib_1.__extends(XDragBoxLayer, _super);
11
+ (0, tslib_1.__extends)(XDragBoxLayer, _super);
11
12
  /**
12
13
  * An XDragBoxLayer is a DragBoxLayer whose size can only be set in the X-direction.
13
14
  * The y-values of the bounds() are always set to 0 and the height() of the XDragBoxLayer.
@@ -4,10 +4,11 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.YDragBoxLayer = void 0;
7
8
  var tslib_1 = require("tslib");
8
9
  var dragBoxLayer_1 = require("./dragBoxLayer");
9
10
  var YDragBoxLayer = /** @class */ (function (_super) {
10
- tslib_1.__extends(YDragBoxLayer, _super);
11
+ (0, tslib_1.__extends)(YDragBoxLayer, _super);
11
12
  /**
12
13
  * A YDragBoxLayer is a DragBoxLayer whose size can only be set in the Y-direction.
13
14
  * The x-values of the bounds() are always set to 0 and the width() of the YDragBoxLayer.
@@ -4,6 +4,7 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.ADD_TITLE_ELEMENTS = exports.SHOW_WARNINGS = void 0;
7
8
  /**
8
9
  * Specifies if Plottable should show warnings.
9
10
  */
@@ -1,3 +1,7 @@
1
+ /**
2
+ * Copyright 2014-present Palantir Technologies
3
+ * @license MIT
4
+ */
1
5
  export declare type DatasetCallback = (dataset: Dataset) => void;
2
6
  export declare class Dataset {
3
7
  private _data;
@@ -59,5 +63,5 @@ export declare class Dataset {
59
63
  */
60
64
  metadata(metadata: any): this;
61
65
  updateId(): number;
62
- private _dispatchUpdate();
66
+ private _dispatchUpdate;
63
67
  }
@@ -4,6 +4,7 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.Dataset = void 0;
7
8
  var Utils = require("../utils");
8
9
  var UPDATE_MONOTONIC = 0;
9
10
  var Dataset = /** @class */ (function () {
@@ -1,3 +1,7 @@
1
+ /**
2
+ * Copyright 2014-present Palantir Technologies
3
+ * @license MIT
4
+ */
1
5
  import { Dataset } from "./dataset";
2
6
  /**
3
7
  * A basic formatter function that will be passed a value to format (e.g. the tick value for axes).
@@ -4,6 +4,7 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.time = exports.multiTime = exports.shortScale = exports.siSuffix = exports.percentage = exports.identity = exports.general = exports.fixed = exports.currency = void 0;
7
8
  var d3 = require("d3");
8
9
  // Do not use utc by default
9
10
  var DEFAULT_USE_UTC = false;
@@ -5,9 +5,9 @@
5
5
  import { Component } from "../components/component";
6
6
  import * as RenderPolicies from "./renderPolicy";
7
7
  export declare const Policy: {
8
+ timeout: "timeout";
8
9
  immediate: "immediate";
9
10
  animationFrame: "animationFrame";
10
- timeout: "timeout";
11
11
  };
12
12
  export declare type Policy = keyof typeof Policy;
13
13
  export declare function renderPolicy(): RenderPolicies.IRenderPolicy;
@@ -4,6 +4,7 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.flush = exports.registerToComputeLayout = exports.registerToComputeLayoutAndRender = exports.registerToRender = exports.renderPolicy = exports.Policy = void 0;
7
8
  var Utils = require("../utils");
8
9
  var makeEnum_1 = require("../utils/makeEnum");
9
10
  var RenderPolicies = require("./renderPolicy");
@@ -27,7 +28,7 @@ var _componentsNeedingRender = new Utils.Set();
27
28
  var _componentsNeedingComputeLayout = new Utils.Set();
28
29
  var _animationRequested = false;
29
30
  var _isCurrentlyFlushing = false;
30
- exports.Policy = makeEnum_1.makeEnum(["immediate", "animationFrame", "timeout"]);
31
+ exports.Policy = (0, makeEnum_1.makeEnum)(["immediate", "animationFrame", "timeout"]);
31
32
  var _renderPolicy = new RenderPolicies.AnimationFrame();
32
33
  function renderPolicy(renderPolicy) {
33
34
  if (renderPolicy == null) {
@@ -1,3 +1,7 @@
1
+ /**
2
+ * Copyright 2014-present Palantir Technologies
3
+ * @license MIT
4
+ */
1
5
  /**
2
6
  * A policy for rendering Components.
3
7
  */
@@ -4,6 +4,7 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.Timeout = exports.AnimationFrame = exports.Immediate = void 0;
7
8
  var Utils = require("../utils");
8
9
  var RenderController = require("./renderController");
9
10
  /**
@@ -1,3 +1,7 @@
1
+ /**
2
+ * Copyright 2014-present Palantir Technologies
3
+ * @license MIT
4
+ */
1
5
  import * as d3Shape from "d3-shape";
2
6
  /**
3
7
  * A SymbolFactory is a function that takes in a symbolSize which is the edge length of the render area
@@ -4,6 +4,7 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.wye = exports.star = exports.triangle = exports.diamond = exports.cross = exports.square = exports.circle = void 0;
7
8
  var d3 = require("d3");
8
9
  function circle() {
9
10
  return function (symbolSize) {
@@ -1 +1,5 @@
1
+ /**
2
+ * Copyright 2014-present Palantir Technologies
3
+ * @license MIT
4
+ */
1
5
  export declare let version: string;
@@ -4,9 +4,10 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.version = void 0;
7
8
  /*
8
9
  * WARNING: The js output of this expression is searched by string (yes, I know) and replaced with a
9
10
  * real version number during the dist phase for for npm module publishing. Modifying this line should
10
11
  * be accompanied by modifying the "sed-version" task in package.json accordingly.
11
12
  */
12
- exports.version = "3.11.0";
13
+ exports.version = "3.12.0";
@@ -4,6 +4,7 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.version = void 0;
7
8
  /*
8
9
  * WARNING: The js output of this expression is searched by string (yes, I know) and replaced with a
9
10
  * real version number during the dist phase for for npm module publishing. Modifying this line should
@@ -1,3 +1,7 @@
1
+ /**
2
+ * Copyright 2014-present Palantir Technologies
3
+ * @license MIT
4
+ */
1
5
  export declare class Dispatcher {
2
6
  /**
3
7
  * Subclasses set these in constructor. Then, these get attached to the event
@@ -18,9 +22,9 @@ export declare class Dispatcher {
18
22
  protected _eventTarget: EventTarget;
19
23
  private _eventNameToCallbackSet;
20
24
  private _connected;
21
- private _hasNoCallbacks();
22
- private _connect();
23
- private _disconnect();
25
+ private _hasNoCallbacks;
26
+ private _connect;
27
+ private _disconnect;
24
28
  protected _addCallbackForEvent(eventName: string, callback: Function): void;
25
29
  protected _removeCallbackForEvent(eventName: string, callback: Function): void;
26
30
  protected _callCallbacksForEvent(eventName: string, ...args: any[]): void;
@@ -4,6 +4,7 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.Dispatcher = void 0;
7
8
  var Utils = require("../utils");
8
9
  var Dispatcher = /** @class */ (function () {
9
10
  function Dispatcher() {
@@ -27,7 +28,7 @@ var Dispatcher = /** @class */ (function () {
27
28
  }
28
29
  Dispatcher.prototype._hasNoCallbacks = function () {
29
30
  var eventNames = Object.keys(this._eventNameToCallbackSet);
30
- for (var i = 0; i < eventNames.length; i++) {
31
+ for (var i = 0; i < eventNames.length; i++) { // for-loop so return can break out
31
32
  if (this._eventNameToCallbackSet[eventNames[i]].size !== 0) {
32
33
  return false;
33
34
  }
@@ -5,6 +5,6 @@
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
7
  var tslib_1 = require("tslib");
8
- tslib_1.__exportStar(require("./keyDispatcher"), exports);
9
- tslib_1.__exportStar(require("./mouseDispatcher"), exports);
10
- tslib_1.__exportStar(require("./touchDispatcher"), exports);
8
+ (0, tslib_1.__exportStar)(require("./keyDispatcher"), exports);
9
+ (0, tslib_1.__exportStar)(require("./mouseDispatcher"), exports);
10
+ (0, tslib_1.__exportStar)(require("./touchDispatcher"), exports);
@@ -22,8 +22,8 @@ export declare class Key extends Dispatcher {
22
22
  * @constructor
23
23
  */
24
24
  constructor();
25
- private _processKeydown(event);
26
- private _processKeyup(event);
25
+ private _processKeydown;
26
+ private _processKeyup;
27
27
  /**
28
28
  * Registers a callback to be called whenever a key is pressed.
29
29
  *
@@ -4,10 +4,11 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.Key = void 0;
7
8
  var tslib_1 = require("tslib");
8
9
  var dispatcher_1 = require("./dispatcher");
9
10
  var Key = /** @class */ (function (_super) {
10
- tslib_1.__extends(Key, _super);
11
+ (0, tslib_1.__extends)(Key, _super);
11
12
  /**
12
13
  * This constructor should not be invoked directly.
13
14
  *
@@ -106,7 +106,7 @@ export declare class Mouse extends Dispatcher {
106
106
  * Computes the mouse position from the given event, and if successful
107
107
  * calls all the callbacks in the provided callbackSet.
108
108
  */
109
- private _measureAndDispatch(component, event, eventName, scope?);
109
+ private _measureAndDispatch;
110
110
  eventInside(component: Component, event: MouseEvent): boolean;
111
111
  /**
112
112
  * Returns the last computed mouse position in <svg> coordinate space.
@@ -4,11 +4,12 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.Mouse = void 0;
7
8
  var tslib_1 = require("tslib");
8
9
  var Utils = require("../utils");
9
10
  var dispatcher_1 = require("./dispatcher");
10
11
  var Mouse = /** @class */ (function (_super) {
11
- tslib_1.__extends(Mouse, _super);
12
+ (0, tslib_1.__extends)(Mouse, _super);
12
13
  /**
13
14
  * This constructor not be invoked directly.
14
15
  *
@@ -90,6 +90,6 @@ export declare class Touch extends Dispatcher {
90
90
  * Computes the Touch position from the given event, and if successful
91
91
  * calls all the callbacks in the provided callbackSet.
92
92
  */
93
- private _measureAndDispatch(component, event, eventName, scope?);
93
+ private _measureAndDispatch;
94
94
  eventInside(component: Component, event: TouchEvent): boolean;
95
95
  }
@@ -4,11 +4,12 @@
4
4
  * @license MIT
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.Touch = void 0;
7
8
  var tslib_1 = require("tslib");
8
9
  var Utils = require("../utils");
9
10
  var dispatcher_1 = require("./dispatcher");
10
11
  var Touch = /** @class */ (function (_super) {
11
- tslib_1.__extends(Touch, _super);
12
+ (0, tslib_1.__extends)(Touch, _super);
12
13
  /**
13
14
  * This constructor should not be invoked directly.
14
15
  *