billboard.js 3.4.0-next.1 → 3.4.1

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 (47) hide show
  1. package/README.md +7 -3
  2. package/dist/billboard.css +1 -1
  3. package/dist/billboard.js +167 -58
  4. package/dist/billboard.min.css +1 -1
  5. package/dist/billboard.min.js +2 -2
  6. package/dist/billboard.pkgd.js +237 -81
  7. package/dist/billboard.pkgd.min.js +2 -2
  8. package/dist/plugin/billboardjs-plugin-bubblecompare.js +2 -2
  9. package/dist/plugin/billboardjs-plugin-bubblecompare.min.js +2 -2
  10. package/dist/plugin/billboardjs-plugin-sparkline.js +12 -7
  11. package/dist/plugin/billboardjs-plugin-sparkline.min.js +2 -2
  12. package/dist/plugin/billboardjs-plugin-stanford.js +12 -7
  13. package/dist/plugin/billboardjs-plugin-stanford.min.js +2 -2
  14. package/dist/plugin/billboardjs-plugin-tableview.js +12 -7
  15. package/dist/plugin/billboardjs-plugin-tableview.min.js +2 -2
  16. package/dist/plugin/billboardjs-plugin-textoverlap.js +12 -7
  17. package/dist/plugin/billboardjs-plugin-textoverlap.min.js +2 -2
  18. package/dist/plugin/pkgd/billboardjs-plugin-bubblecompare.js +2 -2
  19. package/dist/plugin/pkgd/billboardjs-plugin-sparkline.js +58 -21
  20. package/dist/plugin/pkgd/billboardjs-plugin-stanford.js +80 -28
  21. package/dist/plugin/pkgd/billboardjs-plugin-tableview.js +58 -21
  22. package/dist/plugin/pkgd/billboardjs-plugin-textoverlap.js +58 -21
  23. package/dist/theme/datalab.css +1 -1
  24. package/dist/theme/datalab.min.css +1 -1
  25. package/dist/theme/graph.css +1 -1
  26. package/dist/theme/graph.min.css +1 -1
  27. package/dist/theme/insight.css +1 -1
  28. package/dist/theme/insight.min.css +1 -1
  29. package/dist-esm/billboard.js +142 -52
  30. package/dist-esm/plugin/billboardjs-plugin-bubblecompare.js +2 -2
  31. package/dist-esm/plugin/billboardjs-plugin-sparkline.js +2 -2
  32. package/dist-esm/plugin/billboardjs-plugin-stanford.js +7 -4
  33. package/dist-esm/plugin/billboardjs-plugin-tableview.js +2 -2
  34. package/dist-esm/plugin/billboardjs-plugin-textoverlap.js +2 -2
  35. package/package.json +17 -17
  36. package/src/Chart/api/axis.ts +90 -25
  37. package/src/ChartInternal/ChartInternal.ts +25 -11
  38. package/src/ChartInternal/interactions/flow.ts +1 -1
  39. package/src/ChartInternal/shape/arc.ts +1 -1
  40. package/src/ChartInternal/shape/bar.ts +1 -1
  41. package/src/ChartInternal/shape/point.ts +8 -3
  42. package/src/config/Options/common/main.ts +19 -2
  43. package/src/module/generator.ts +19 -5
  44. package/src/module/util.ts +6 -3
  45. package/types/chart.d.ts +8 -8
  46. package/types/options.d.ts +7 -2
  47. package/types/types.d.ts +2 -0
package/README.md CHANGED
@@ -40,7 +40,7 @@ If you have any questions, checkout the previous posts or create a new one at:
40
40
  - [Issue with 'question' label](https://github.com/naver/billboard.js/issues?utf8=%E2%9C%93&q=label%3Aquestion)
41
41
 
42
42
  ## Supported chart types
43
- <img src="https://naver.github.io/billboard.js/img/chart-types.png?v=9" width=800>
43
+ <img src="https://naver.github.io/billboard.js/img/chart-types.png?v=10" width=800>
44
44
 
45
45
  ## Download and Installation
46
46
 
@@ -147,11 +147,15 @@ If you want to use 'billboard.js' without installation, load files directly from
147
147
 
148
148
  ## Supported Browsers
149
149
 
150
- > Basically will work on all SVG supported browsers.
150
+ > - Basically will work on all SVG supported browsers.
151
+ > - <sup>*</sup>Notes for legacy browsers:
152
+ > - Recommended to use `packaged` build or construct your own build following [`How to bundle for legacy browsers?`](https://github.com/naver/billboard.js/wiki/How-to-bundle-for-legacy-browsers%3F) instruction.
153
+ > - D3.js dropped the support of legacy browsers since [v6](https://observablehq.com/@d3/d3v6-migration-guide).
154
+ > - The support isn't fully guaranteed.
151
155
 
152
156
  |Internet Explorer|Chrome|Firefox|Safari|iOS|Android|
153
157
  |---|---|---|---|---|---|
154
- |9+|Latest|Latest|Latest|8+|4+|
158
+ |9+<sup>*</sup>|Latest|Latest|Latest|8+|4+|
155
159
 
156
160
 
157
161
  ## Dependency by version
@@ -5,7 +5,7 @@
5
5
  * billboard.js, JavaScript chart library
6
6
  * https://naver.github.io/billboard.js/
7
7
  *
8
- * @version 3.4.0-next.1
8
+ * @version 3.4.1
9
9
  */
10
10
  /*-- Chart --*/
11
11
  .bb svg {
package/dist/billboard.js CHANGED
@@ -5,7 +5,7 @@
5
5
  * billboard.js, JavaScript chart library
6
6
  * https://naver.github.io/billboard.js/
7
7
  *
8
- * @version 3.4.0-next.1
8
+ * @version 3.4.1
9
9
  */
10
10
  (function webpackUniversalModuleDefinition(root, factory) {
11
11
  if(typeof exports === 'object' && typeof module === 'object')
@@ -1087,9 +1087,13 @@ function parseDate(date) {
1087
1087
  if (date instanceof Date) {
1088
1088
  parsedDate = date;
1089
1089
  } else if (isString(date)) {
1090
- var config = this.config,
1090
+ var _format$dataTime,
1091
+ config = this.config,
1091
1092
  format = this.format;
1092
- parsedDate = format.dataTime(config.data_xFormat)(date);
1093
+
1094
+ // if fails to parse, try by new Date()
1095
+ // https://github.com/naver/billboard.js/issues/1714
1096
+ parsedDate = (_format$dataTime = format.dataTime(config.data_xFormat)(date)) != null ? _format$dataTime : new Date(date);
1093
1097
  } else if (isNumber(date) && !isNaN(date)) {
1094
1098
  parsedDate = new Date(+date);
1095
1099
  }
@@ -1108,7 +1112,7 @@ function parseDate(date) {
1108
1112
 
1109
1113
 
1110
1114
  function isTabVisible() {
1111
- return !browser_doc.hidden;
1115
+ return (browser_doc == null ? void 0 : browser_doc.hidden) === !1 || (browser_doc == null ? void 0 : browser_doc.visibilityState) === "visible";
1112
1116
  }
1113
1117
  /**
1114
1118
  * Get the current input type
@@ -1149,8 +1153,9 @@ function convertInputType(mouse, touch) {
1149
1153
 
1150
1154
  var hasMouse = mouse && ["any-hover:hover", "any-pointer:fine"].some(function (v) {
1151
1155
  return matchMedia == null ? void 0 : matchMedia("(" + v + ")").matches;
1152
- });
1153
- return hasMouse && "mouse" || hasTouch && "touch" || null;
1156
+ }); // fallback to 'mouse' if no input type is detected.
1157
+
1158
+ return hasMouse && "mouse" || hasTouch && "touch" || "mouse";
1154
1159
  }
1155
1160
  ;// CONCATENATED MODULE: ./src/module/error.ts
1156
1161
 
@@ -1806,6 +1811,21 @@ var Store = /*#__PURE__*/function () {
1806
1811
  */
1807
1812
  resize_auto: !0,
1808
1813
 
1814
+ /**
1815
+ * Set a callback to execute when the chart is clicked.
1816
+ * @name onclick
1817
+ * @memberof Options
1818
+ * @type {Function}
1819
+ * @default undefined
1820
+ * @example
1821
+ * onclick: function(event) {
1822
+ * this; // chart instance itself
1823
+ * event; // native event object
1824
+ * ...
1825
+ * }
1826
+ */
1827
+ onclick: undefined,
1828
+
1809
1829
  /**
1810
1830
  * Set a callback to execute when mouse/touch enters the chart.
1811
1831
  * @name onover
@@ -1813,8 +1833,9 @@ var Store = /*#__PURE__*/function () {
1813
1833
  * @type {Function}
1814
1834
  * @default undefined
1815
1835
  * @example
1816
- * onover: function() {
1836
+ * onover: function(event) {
1817
1837
  * this; // chart instance itself
1838
+ * event; // native event object
1818
1839
  * ...
1819
1840
  * }
1820
1841
  */
@@ -1827,8 +1848,9 @@ var Store = /*#__PURE__*/function () {
1827
1848
  * @type {Function}
1828
1849
  * @default undefined
1829
1850
  * @example
1830
- * onout: function() {
1851
+ * onout: function(event) {
1831
1852
  * this; // chart instance itself
1853
+ * event; // native event object
1832
1854
  * ...
1833
1855
  * }
1834
1856
  */
@@ -3591,28 +3613,38 @@ function generateResize() {
3591
3613
 
3592
3614
  return callResizeFn;
3593
3615
  }
3616
+
3594
3617
  /**
3595
3618
  * Generate transition queue function
3596
3619
  * @returns {Function}
3597
3620
  * @private
3598
3621
  */
3599
-
3600
3622
  function generateWait() {
3601
3623
  var transitionsToWait = [],
3602
- f = function (t, callback) {
3603
- var timer; // eslint-disable-next-line
3624
+ f = function (selection, callback) {
3625
+ var timer;
3626
+ /**
3627
+ * Check if transition is complete
3628
+ * @private
3629
+ */
3604
3630
 
3605
3631
  function loop() {
3606
3632
  var done = 0;
3607
3633
 
3608
- for (var i = 0, _t; _t = transitionsToWait[i]; i++) {
3609
- if (_t === !0 || _t.empty != null && _t.empty()) {
3634
+ for (var i = 0, t; t = transitionsToWait[i]; i++) {
3635
+ if (t === !0 || t.empty != null && t.empty()) {
3610
3636
  done++;
3611
3637
  continue;
3638
+ } // when tab isn't visible exit loop
3639
+
3640
+
3641
+ if (isTabVisible() === !1) {
3642
+ done = transitionsToWait.length;
3643
+ break;
3612
3644
  }
3613
3645
 
3614
3646
  try {
3615
- _t.transition();
3647
+ t.transition();
3616
3648
  } catch (e) {
3617
3649
  done++;
3618
3650
  }
@@ -3628,7 +3660,8 @@ function generateWait() {
3628
3660
  }
3629
3661
 
3630
3662
  loop();
3631
- };
3663
+ }; // 'f' is called as selection.call(f, ...);
3664
+
3632
3665
 
3633
3666
  f.add = function (t) {
3634
3667
  isArray(t) ? transitionsToWait = transitionsToWait.concat(t) : transitionsToWait.push(t);
@@ -9754,10 +9787,9 @@ var ChartInternal = /*#__PURE__*/function () {
9754
9787
 
9755
9788
  _proto.initParams = function initParams() {
9756
9789
  var $$ = this,
9757
- _ref = $$,
9758
- config = _ref.config,
9759
- format = _ref.format,
9760
- state = _ref.state,
9790
+ config = $$.config,
9791
+ format = $$.format,
9792
+ state = $$.state,
9761
9793
  isRotated = config.axis_rotated;
9762
9794
  // datetime to be used for uniqueness
9763
9795
  state.datetimeId = "bb-" + +new Date() * getRandom();
@@ -9861,12 +9893,16 @@ var ChartInternal = /*#__PURE__*/function () {
9861
9893
  $el.svg = $el.chart.append("svg").style("overflow", "hidden").style("display", "block");
9862
9894
 
9863
9895
  if (hasInteraction && state.inputType) {
9864
- var isTouch = state.inputType === "touch";
9865
- $el.svg.on(isTouch ? "touchstart" : "mouseenter", function () {
9866
- return callFn(config.onover, $$.api);
9867
- }).on(isTouch ? "touchend" : "mouseleave", function () {
9868
- return callFn(config.onout, $$.api);
9869
- });
9896
+ var _onclick,
9897
+ _onover,
9898
+ _onout,
9899
+ isTouch = state.inputType === "touch",
9900
+ _config = config,
9901
+ onclick = _config.onclick,
9902
+ onover = _config.onover,
9903
+ onout = _config.onout;
9904
+
9905
+ $el.svg.on("click", ((_onclick = onclick) == null ? void 0 : _onclick.bind($$.api)) || null).on(isTouch ? "touchstart" : "mouseenter", ((_onover = onover) == null ? void 0 : _onover.bind($$.api)) || null).on(isTouch ? "touchend" : "mouseleave", ((_onout = onout) == null ? void 0 : _onout.bind($$.api)) || null);
9870
9906
  }
9871
9907
 
9872
9908
  config.svg_classname && $el.svg.attr("class", config.svg_classname); // Define defs
@@ -10114,27 +10150,40 @@ var ChartInternal = /*#__PURE__*/function () {
10114
10150
  }
10115
10151
 
10116
10152
  helper(_type);
10117
- } // circle
10153
+ } // Point types
10154
+
10118
10155
 
10156
+ var hasPointType = $$.hasType("bubble") || $$.hasType("scatter");
10119
10157
 
10120
- if ($$.hasType("bubble") || $$.hasType("scatter")) {
10158
+ if (hasPointType) {
10121
10159
  $$.updateTargetForCircle == null ? void 0 : $$.updateTargetForCircle();
10122
10160
  } // Fade-in each chart
10123
10161
 
10124
10162
 
10125
- $$.showTargets();
10163
+ $$.filterTargetsToShowAtInit(hasPointType);
10126
10164
  }
10127
10165
  /**
10128
- * Display targeted elements
10166
+ * Display targeted elements at initialization
10167
+ * @param {boolean} hasPointType whether has point type(bubble, scatter) or not
10129
10168
  * @private
10130
10169
  */
10131
10170
  ;
10132
10171
 
10133
- _proto.showTargets = function showTargets() {
10172
+ _proto.filterTargetsToShowAtInit = function filterTargetsToShowAtInit(hasPointType) {
10173
+ if (hasPointType === void 0) {
10174
+ hasPointType = !1;
10175
+ }
10176
+
10134
10177
  var $$ = this,
10135
10178
  svg = $$.$el.svg,
10136
- $T = $$.$T;
10137
- $T(svg.selectAll("." + $COMMON.target).filter(function (d) {
10179
+ $T = $$.$T,
10180
+ selector = "." + $COMMON.target;
10181
+
10182
+ if (hasPointType) {
10183
+ selector += ", ." + $CIRCLE.chartCircles + " > ." + $CIRCLE.circles;
10184
+ }
10185
+
10186
+ $T(svg.selectAll(selector).filter(function (d) {
10138
10187
  return $$.isTargetToShow(d.id);
10139
10188
  })).style("opacity", null);
10140
10189
  };
@@ -10169,8 +10218,9 @@ var ChartInternal = /*#__PURE__*/function () {
10169
10218
 
10170
10219
  _proto.initialOpacity = function initialOpacity(d) {
10171
10220
  var $$ = this,
10172
- withoutFadeIn = $$.state.withoutFadeIn;
10173
- return $$.getBaseValue(d) !== null && withoutFadeIn[d.id] ? null : "0";
10221
+ withoutFadeIn = $$.state.withoutFadeIn,
10222
+ r = $$.getBaseValue(d) !== null && withoutFadeIn[d.id] ? null : "0";
10223
+ return r;
10174
10224
  };
10175
10225
 
10176
10226
  _proto.bindResize = function bindResize() {
@@ -11618,6 +11668,7 @@ extend(Chart.prototype, [chart, api_color, api_data, api_export, api_focus, api_
11618
11668
  * billboard.js project is licensed under the MIT license
11619
11669
  */
11620
11670
 
11671
+
11621
11672
  /**
11622
11673
  * Set the min/max value
11623
11674
  * @param {Chart} $$ Chart instance
@@ -11625,20 +11676,26 @@ extend(Chart.prototype, [chart, api_color, api_data, api_export, api_focus, api_
11625
11676
  * @param {object} value Value to be set
11626
11677
  * @private
11627
11678
  */
11628
-
11629
11679
  function setMinMax($$, type, value) {
11630
11680
  var config = $$.config,
11631
- axisY = "axis_y_" + type,
11632
- axisY2 = "axis_y2_" + type;
11681
+ helper = function (key, value) {
11682
+ var v = isNumber(value) ? value : value === !1 ? undefined : null;
11683
+
11684
+ if (v !== null) {
11685
+ config["axis_" + key + "_" + type] = v;
11686
+ }
11687
+ };
11633
11688
 
11634
11689
  if (isDefined(value)) {
11635
11690
  if (isObjectType(value)) {
11636
- isValue(value.x) && (config["axis_x_" + type] = value.x);
11637
- isValue(value.y) && (config[axisY] = value.y);
11638
- isValue(value.y2) && (config[axisY2] = value.y2);
11639
- } else {
11640
- config[axisY] = value;
11641
- config[axisY2] = value;
11691
+ Object.keys(value).forEach(function (key) {
11692
+ helper(key, value[key]);
11693
+ });
11694
+ } else if (isNumber(value) || value === !1) {
11695
+ // shorthand values affects only y and y2.
11696
+ ["y", "y2"].forEach(function (key) {
11697
+ helper(key, value);
11698
+ });
11642
11699
  }
11643
11700
 
11644
11701
  $$.redraw({
@@ -11724,8 +11781,9 @@ var axis = {
11724
11781
  * @instance
11725
11782
  * @memberof Chart
11726
11783
  * @param {object} min If min is given, specified axis' min value will be updated.<br>
11727
- * If no argument is given, the min values set on generating option for each axis will be returned.
11728
- * If not set any min values on generation, it will return `undefined`.
11784
+ * If no argument is given, the min values set on generating option for each axis will be returned.
11785
+ * If not set any min values on generation, it will return `undefined`.<br>
11786
+ * To unset specific axis max, set `false` to each of them.
11729
11787
  * @returns {object|undefined}
11730
11788
  * @example
11731
11789
  * // Update axis' min
@@ -11734,10 +11792,21 @@ var axis = {
11734
11792
  * y: 1000,
11735
11793
  * y2: 100
11736
11794
  * });
11795
+ *
11796
+ * // To unset specific axis min, set false to each of them.
11797
+ * chart.axis.min({
11798
+ * x: false,
11799
+ * y: false,
11800
+ * y2: false
11801
+ * });
11802
+ *
11803
+ * // shorthand (only affects y and y2 axis)
11804
+ * chart.axis.min(-50);
11805
+ * chart.axis.min(false);
11737
11806
  */
11738
11807
  min: function min(_min) {
11739
11808
  var $$ = this.internal;
11740
- return isValue(_min) ? setMinMax($$, "min", _min) : axis_getMinMax($$, "min");
11809
+ return isValue(_min) || _min === !1 ? setMinMax($$, "min", _min) : axis_getMinMax($$, "min");
11741
11810
  },
11742
11811
 
11743
11812
  /**
@@ -11746,8 +11815,9 @@ var axis = {
11746
11815
  * @instance
11747
11816
  * @memberof Chart
11748
11817
  * @param {object} max If max is given, specified axis' max value will be updated.<br>
11749
- * If no argument is given, the max values set on generating option for each axis will be returned.
11750
- * If not set any max values on generation, it will return `undefined`.
11818
+ * If no argument is given, the max values set on generating option for each axis will be returned.
11819
+ * If not set any max values on generation, it will return `undefined`.<br>
11820
+ * To unset specific axis max, set `false` to each of them.
11751
11821
  * @returns {object|undefined}
11752
11822
  * @example
11753
11823
  * // Update axis' label
@@ -11756,10 +11826,21 @@ var axis = {
11756
11826
  * y: 1000,
11757
11827
  * y2: 10000
11758
11828
  * });
11829
+ *
11830
+ * // To unset specific axis max, set false to each of them.
11831
+ * chart.axis.max({
11832
+ * x: false,
11833
+ * y: false,
11834
+ * y2: false
11835
+ * });
11836
+ *
11837
+ * // shorthand (only affects y and y2 axis)
11838
+ * chart.axis.max(10);
11839
+ * chart.axis.max(false);
11759
11840
  */
11760
11841
  max: function max(_max) {
11761
11842
  var $$ = this.internal;
11762
- return arguments.length ? setMinMax($$, "max", _max) : axis_getMinMax($$, "max");
11843
+ return isValue(_max) || _max === !1 ? setMinMax($$, "max", _max) : axis_getMinMax($$, "max");
11763
11844
  },
11764
11845
 
11765
11846
  /**
@@ -11767,7 +11848,9 @@ var axis = {
11767
11848
  * @function axis․range
11768
11849
  * @instance
11769
11850
  * @memberof Chart
11770
- * @param {object} range If range is given, specified axis' min and max value will be updated. If no argument is given, the current min and max values for each axis will be returned.
11851
+ * @param {object} range If range is given, specified axis' min and max value will be updated.
11852
+ * If no argument is given, the current min and max values for each axis will be returned.<br>
11853
+ * To unset specific axis max, set `false` to each of them.
11771
11854
  * @returns {object|undefined}
11772
11855
  * @example
11773
11856
  * // Update axis' label
@@ -11783,13 +11866,33 @@ var axis = {
11783
11866
  * y2: 10000
11784
11867
  * },
11785
11868
  * });
11869
+ *
11870
+ * // To unset specific axis max, set false to each of them.
11871
+ * chart.axis.range({
11872
+ * min: {
11873
+ * x: false,
11874
+ * y: false,
11875
+ * y2: false
11876
+ * },
11877
+ * max: {
11878
+ * x: false,
11879
+ * y: false,
11880
+ * y2: false
11881
+ * },
11882
+ * });
11883
+ *
11884
+ * // shorthand (only affects y and y2 axis)
11885
+ * chart.axis.range({ min: -50, max: 1000 });
11886
+ * chart.axis.range({ min: false, max: false });
11786
11887
  */
11787
11888
  range: function range(_range) {
11788
11889
  var axis = this.axis;
11789
11890
 
11790
11891
  if (arguments.length) {
11791
- isDefined(_range.max) && axis.max(_range.max);
11792
- isDefined(_range.min) && axis.min(_range.min);
11892
+ var min = _range.min,
11893
+ max = _range.max;
11894
+ isDefined(max) && axis.max(max);
11895
+ isDefined(min) && axis.min(min);
11793
11896
  } else {
11794
11897
  return {
11795
11898
  max: axis.max(),
@@ -14764,7 +14867,9 @@ var external_commonjs_d3_ease_commonjs2_d3_ease_amd_d3_ease_root_d3_ = __webpack
14764
14867
  } else if (orgDataCount === 1 || ((_flowStart = flowStart) == null ? void 0 : _flowStart.x) === ((_flowEnd = flowEnd) == null ? void 0 : _flowEnd.x)) {
14765
14868
  translateX = x(orgDomain[0]) - x(domain[0]);
14766
14869
  } else {
14767
- translateX = $$.axis.isTimeSeries() ? x(orgDomain[0]) - x(domain[0]) : x(flowStart.x) - x(flowEnd.x);
14870
+ var _flowStart2;
14871
+
14872
+ translateX = $$.axis.isTimeSeries() ? x(orgDomain[0]) - x(domain[0]) : x(((_flowStart2 = flowStart) == null ? void 0 : _flowStart2.x) || 0) - x(flowEnd.x);
14768
14873
  }
14769
14874
 
14770
14875
  var scaleX = diffDomain(orgDomain) / diffDomain(domain);
@@ -17764,7 +17869,7 @@ var external_commonjs_d3_interpolate_commonjs2_d3_interpolate_amd_d3_interpolate
17764
17869
 
17765
17870
  /**
17766
17871
  * Set transform attributes to arc label text
17767
- * @param {Object} d Data object
17872
+ * @param {object} d Data object
17768
17873
  * @returns {string} Translate attribute string
17769
17874
  * @private
17770
17875
  */
@@ -18585,7 +18690,7 @@ var external_commonjs_d3_interpolate_commonjs2_d3_interpolate_amd_d3_interpolate
18585
18690
 
18586
18691
  /**
18587
18692
  * Determine if given stacking bar data is radius type
18588
- * @param {Object} d Data row
18693
+ * @param {object} d Data row
18589
18694
  * @returns {boolean}
18590
18695
  */
18591
18696
  isStackingRadiusData: function isStackingRadiusData(d) {
@@ -19444,7 +19549,7 @@ var getTransitionName = function () {
19444
19549
  targets = data.targets.filter(function (d) {
19445
19550
  return _this.isScatterType(d) || _this.isBubbleType(d);
19446
19551
  });
19447
- var mainCircle = $el.main.select("." + $CIRCLE.chartCircles).style("pointer-events", "none").selectAll("." + $CIRCLE.circles).data(targets).attr("class", classCircles);
19552
+ var mainCircle = $el.main.select("." + $CIRCLE.chartCircles).style("pointer-events", "none").selectAll("." + $CIRCLE.circles).data(targets);
19448
19553
  mainCircle.exit().remove();
19449
19554
  enterNode = mainCircle.enter();
19450
19555
  } // Circles for each data point on lines
@@ -19455,6 +19560,10 @@ var getTransitionName = function () {
19455
19560
  });
19456
19561
  enterNode.append("g").attr("class", classCircles).style("cursor", function (d) {
19457
19562
  return isFunction(isSelectable) && isSelectable(d) ? "pointer" : null;
19563
+ }).style("opacity", function () {
19564
+ var parent = (0,external_commonjs_d3_selection_commonjs2_d3_selection_amd_d3_selection_root_d3_.select)(this.parentNode); // if the parent node is .bb-chart-circles (bubble, scatter), initialize <g bb-circles> with opacity "0"
19565
+
19566
+ return parent.attr("class").indexOf($CIRCLE.chartCircles) > -1 ? "0" : null;
19458
19567
  }); // Update date for selected circles
19459
19568
 
19460
19569
  selectionEnabled && targets.forEach(function (t) {
@@ -23328,7 +23437,7 @@ var _defaults = {},
23328
23437
  * bb.version; // "1.0.0"
23329
23438
  * @memberof bb
23330
23439
  */
23331
- version: "3.4.0-next.1",
23440
+ version: "3.4.1",
23332
23441
 
23333
23442
  /**
23334
23443
  * Generate chart
@@ -23463,7 +23572,7 @@ var _defaults = {},
23463
23572
  };
23464
23573
  /**
23465
23574
  * @namespace bb
23466
- * @version 3.4.0-next.1
23575
+ * @version 3.4.1
23467
23576
  */
23468
23577
  ;// CONCATENATED MODULE: ./src/index.ts
23469
23578
  /**
@@ -5,5 +5,5 @@
5
5
  * billboard.js, JavaScript chart library
6
6
  * https://naver.github.io/billboard.js/
7
7
  *
8
- * @version 3.4.0-next.1
8
+ * @version 3.4.1
9
9
  */.bb svg{-webkit-tap-highlight-color:rgba(0,0,0,0);font:10px sans-serif}.bb line,.bb path{fill:none;stroke:#000}.bb .bb-button,.bb text{-webkit-user-select:none;-moz-user-select:none;user-select:none}.bb-bars path,.bb-event-rect,.bb-legend-item-tile,.bb-xgrid-focus,.bb-ygrid,.bb-ygrid-focus{shape-rendering:crispEdges}.bb-chart-arc .bb-gauge-value{fill:#000}.bb-chart-arc path{stroke:#fff}.bb-chart-arc rect{stroke:#fff;stroke-width:1}.bb-chart-arc text{fill:#fff;font-size:13px}.bb-axis{shape-rendering:crispEdges}.bb-grid{pointer-events:none}.bb-grid line{stroke:#aaa}.bb-grid text{fill:#aaa}.bb-xgrid,.bb-ygrid{stroke-dasharray:3 3}.bb-text.bb-empty{fill:grey;font-size:2em}.bb-line{stroke-width:1px}.bb-circle._expanded_{stroke-width:1px;stroke:#fff}.bb-selected-circle{fill:#fff;stroke-width:2px}.bb-bar{stroke-width:0}.bb-bar._expanded_{fill-opacity:.75}.bb-candlestick{stroke-width:1px}.bb-candlestick._expanded_{fill-opacity:.75}.bb-circles.bb-focused,.bb-target.bb-focused{opacity:1}.bb-circles.bb-focused path.bb-line,.bb-circles.bb-focused path.bb-step,.bb-target.bb-focused path.bb-line,.bb-target.bb-focused path.bb-step{stroke-width:2px}.bb-circles.bb-defocused,.bb-target.bb-defocused{opacity:.3!important}.bb-circles.bb-defocused .text-overlapping,.bb-target.bb-defocused .text-overlapping{opacity:.05!important}.bb-region{fill:#4682b4}.bb-brush .extent,.bb-region,.bb-zoom-brush{fill-opacity:.1}.bb-legend-item{font-size:12px;user-select:none}.bb-legend-item-hidden{opacity:.15}.bb-legend-background{fill:#fff;stroke:#d3d3d3;stroke-width:1;opacity:.75}.bb-title{font:14px sans-serif}.bb-tooltip-container{user-select:none;z-index:10}.bb-tooltip{background-color:#fff;border-collapse:collapse;border-spacing:0;-webkit-box-shadow:7px 7px 12px -9px #777;-moz-box-shadow:7px 7px 12px -9px #777;box-shadow:7px 7px 12px -9px #777;empty-cells:show;opacity:.9}.bb-tooltip tr{border:1px solid #ccc}.bb-tooltip th{background-color:#aaa;color:#fff;font-size:14px;padding:2px 5px;text-align:left}.bb-tooltip td{background-color:#fff;border-left:1px dotted #999;font-size:13px;padding:3px 6px}.bb-tooltip td>span,.bb-tooltip td>svg{display:inline-block;height:10px;margin-right:6px;width:10px}.bb-tooltip.value{text-align:right}.bb-area{stroke-width:0;opacity:.2}.bb-chart-arcs-title{dominant-baseline:middle;font-size:1.3em}text.bb-chart-arcs-gauge-title{dominant-baseline:middle;font-size:2.7em}.bb-chart-arcs .bb-chart-arcs-background{fill:#e0e0e0;stroke:#fff}.bb-chart-arcs .bb-chart-arcs-gauge-unit{fill:#000;font-size:16px}.bb-chart-arcs .bb-chart-arcs-gauge-max,.bb-chart-arcs .bb-chart-arcs-gauge-min{fill:#777}.bb-chart-arcs .bb-levels circle{fill:none;stroke:#848282;stroke-width:.5px}.bb-chart-arcs .bb-levels text{fill:#848282}.bb-chart-radars .bb-levels polygon{fill:none;stroke:#848282;stroke-width:.5px}.bb-chart-radars .bb-levels text{fill:#848282}.bb-chart-radars .bb-axis line{stroke:#848282;stroke-width:.5px}.bb-chart-radars .bb-axis text{cursor:default;font-size:1.15em}.bb-chart-radars .bb-shapes polygon{fill-opacity:.2;stroke-width:1px}.bb-button{position:absolute;right:10px;top:10px}.bb-button .bb-zoom-reset{background-color:#fff;border:1px solid #ccc;border-radius:5px;cursor:pointer;font-size:11px;padding:5px}