billboard.js 3.9.0 → 3.9.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.
- package/README.md +5 -1
- package/dist/billboard.css +1 -1
- package/dist/billboard.js +100 -83
- package/dist/billboard.min.css +1 -1
- package/dist/billboard.min.js +2 -2
- package/dist/billboard.pkgd.js +340 -192
- package/dist/billboard.pkgd.min.js +2 -2
- package/dist/plugin/billboardjs-plugin-bubblecompare.js +2 -2
- package/dist/plugin/billboardjs-plugin-bubblecompare.min.js +2 -2
- package/dist/plugin/billboardjs-plugin-sparkline.js +3 -3
- package/dist/plugin/billboardjs-plugin-sparkline.min.js +2 -2
- package/dist/plugin/billboardjs-plugin-stanford.js +2 -2
- package/dist/plugin/billboardjs-plugin-stanford.min.js +2 -2
- package/dist/plugin/billboardjs-plugin-tableview.js +3 -3
- package/dist/plugin/billboardjs-plugin-tableview.min.js +2 -2
- package/dist/plugin/billboardjs-plugin-textoverlap.js +2 -2
- package/dist/plugin/billboardjs-plugin-textoverlap.min.js +2 -2
- package/dist/plugin/pkgd/billboardjs-plugin-bubblecompare.js +242 -111
- package/dist/plugin/pkgd/billboardjs-plugin-sparkline.js +243 -112
- package/dist/plugin/pkgd/billboardjs-plugin-stanford.js +242 -111
- package/dist/plugin/pkgd/billboardjs-plugin-tableview.js +243 -112
- package/dist/plugin/pkgd/billboardjs-plugin-textoverlap.js +242 -111
- package/dist/theme/dark.css +1 -1
- package/dist/theme/dark.min.css +1 -1
- package/dist/theme/datalab.css +1 -1
- package/dist/theme/datalab.min.css +1 -1
- package/dist/theme/graph.css +1 -1
- package/dist/theme/graph.min.css +1 -1
- package/dist/theme/insight.css +1 -1
- package/dist/theme/insight.min.css +1 -1
- package/dist-esm/billboard.js +71 -54
- package/dist-esm/plugin/billboardjs-plugin-bubblecompare.js +2 -2
- package/dist-esm/plugin/billboardjs-plugin-sparkline.js +2 -2
- package/dist-esm/plugin/billboardjs-plugin-stanford.js +2 -2
- package/dist-esm/plugin/billboardjs-plugin-tableview.js +2 -2
- package/dist-esm/plugin/billboardjs-plugin-textoverlap.js +2 -2
- package/package.json +23 -23
- package/src/ChartInternal/data/data.ts +2 -12
- package/src/ChartInternal/interactions/eventrect.ts +7 -4
- package/src/ChartInternal/internals/tooltip.ts +55 -41
- package/src/ChartInternal/shape/point.ts +20 -2
package/dist/theme/dark.css
CHANGED
package/dist/theme/dark.min.css
CHANGED
|
@@ -5,5 +5,5 @@
|
|
|
5
5
|
* billboard.js, JavaScript chart library
|
|
6
6
|
* https://naver.github.io/billboard.js/
|
|
7
7
|
*
|
|
8
|
-
* @version 3.9.
|
|
8
|
+
* @version 3.9.1
|
|
9
9
|
*/.bb-color-pattern{background-image:url(#4a7fff;#b02c2c;#1ca46c;#b47300;#49baf3;#ed7e13;#cfaa00;#a6cd19;#dccb52;#f5d194;)}.bb svg{font-family:Helvetica,Arial,sans-serif,nanumgothic,Dotum;font-size:12px;line-height:1}.bb line,.bb path{fill:none;stroke:#8d9cab}.bb .bb-button,.bb text{fill:#8d9cab;font-size:11px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.bb-legend-item-title,.bb-line,.bb-xgrid-focus,.bb-ygrid,.bb-ygrid-focus{shape-rendering:crispEdges}.bb-chart-arcs .bb-needle{fill:#8d9cab}.bb-axis{shape-rendering:crispEdges}.bb-axis-y text,.bb-axis-y2 text{fill:#8d9cab}.bb-event-rects{fill-opacity:1!important}.bb-event-rects .bb-event-rect{fill:transparent}.bb-event-rects .bb-event-rect._active_{fill:rgba(39,201,3,.05)}.tick._active_ text{fill:#00c83c!important}.bb-grid{pointer-events:none}.bb-grid line{stroke:#5c666e}.bb-xgrid-focus line,.bb-ygrid-focus line{stroke:#ccd9e6}.bb-text.bb-empty{fill:#8d9cab}.bb-line{stroke-width:1px}.bb-circle._expanded_{stroke-width:2px;stroke:8d9cab}rect.bb-circle._expanded_,use.bb-circle._expanded_{stroke-width:1px}.selection{stroke:none;fill:#ccd9e6}.bb-selected-circle{fill:#ccd9e6;stroke-width:2px}.bb-bar{stroke-width:.5px}.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:.5!important}.bb-circles.bb-defocused .text-overlapping,.bb-target.bb-defocused .text-overlapping{opacity:.05!important}.bb-region{fill:#4682b4;fill-opacity:.5}.bb-region.selected rect{fill:#27c903}.bb-zoom-brush{fill-opacity:.25;fill:#ccd9e6}.bb-brush .extent{fill-opacity:.5}.bb-legend-item{user-select:none}.bb-legend-item line{stroke-width:10px;stroke-dasharray:3px}.bb-legend-item text{transform:translateY(-1px)}.bb-legend-item-hidden{opacity:.5}.bb-legend-background{stroke:#d3d3d3;stroke-width:1;opacity:.75}.bb-title{font-size:14px}.bb-chart-treemaps rect{stroke:#8d9cab;stroke-width:1px}.bb-tooltip-container{font-family:Helvetica,Arial,sans-serif,nanumgothic,Dotum;user-select:none;z-index:10}.bb-tooltip{background-color:#000;border:1px solid #828181;border-collapse:separate;border-radius:5px;border-spacing:0;color:#fff;empty-cells:show;font-size:11px;text-align:left;white-space:nowrap}.bb-tooltip th{border-bottom:1px solid #828181;font-size:12px;padding:4px 8px;text-align:left}.bb-tooltip td{padding:4px 6px}.bb-tooltip td:first-child{padding-left:8px}.bb-tooltip td:last-child{padding-right:8px}.bb-tooltip td>span,.bb-tooltip td>svg{display:inline-block;height:7px;margin:-1px 6px 0 0;vertical-align:middle;width:7px}.bb-tooltip td.value{border-left:1px solid transparent;text-align:right}.bb-tooltip .bb-tooltip-title{color:#aaa;display:inline-block;line-height:20px}.bb-tooltip .bb-tooltip-detail table{border-collapse:collapse;border-spacing:0}.bb-tooltip .bb-tooltip-detail .bb-tooltip-name,.bb-tooltip .bb-tooltip-detail .bb-tooltip-value{color:#444;font-size:11px;font-weight:400;line-height:13px;padding:4px 0 3px;text-align:left}.bb-tooltip .bb-tooltip-detail .bb-tooltip-value{font-size:12px;font-weight:800;padding-left:5px}.bb-area{stroke-width:0;opacity:.5}.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:#3f3f3f;stroke:none}.bb-chart-arcs .bb-chart-arcs-gauge-unit{fill:#828181;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-chart-arcs-title{fill:#b6c2ce;font-size:16px!important;font-weight:600}.bb-chart-arcs path.empty{fill:#eaeaea;stroke-width:0}.bb-chart-arcs .bb-levels circle{fill:none;stroke:#848282;stroke-width:.5px}.bb-chart-arcs .bb-levels text{fill:#848282}.bb-chart-arc .bb-gauge-value{fill:#b6c2ce}.bb-chart-arc rect{stroke:#8d9cab;stroke-width:1}.bb-chart-arc text{fill:#fff;font-size:13px}.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:#000;border:1px solid #ccc;border-radius:5px;color:#fff;cursor:pointer;padding:5px}
|
package/dist/theme/datalab.css
CHANGED
|
@@ -5,5 +5,5 @@
|
|
|
5
5
|
* billboard.js, JavaScript chart library
|
|
6
6
|
* https://naver.github.io/billboard.js/
|
|
7
7
|
*
|
|
8
|
-
* @version 3.9.
|
|
8
|
+
* @version 3.9.1
|
|
9
9
|
*/.bb-color-pattern{background-image:url(#2ac4b3;#feaf29;#ff617b;#73a2ef;#b180d0;#3064cf;#d0a45f;#8aaec7;#ef65a2;#8aaec7;)}.bb svg{font-family:Sans Pro,Arial,sans-serif,nanumgothic,Dotum;font-size:11px;line-height:1}.bb line,.bb path{fill:none;stroke:#000}.bb .bb-button,.bb text{-webkit-font-smoothing:antialiased;fill:#555;font-size:11px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.bb-chart-arcs .bb-needle{fill:#000}.bb-axis{stroke-width:.7px}.bb-axis-y text,.bb-axis-y2 text{fill:#737373}.bb-event-rects{fill-opacity:1!important}.bb-event-rects .bb-event-rect{fill:transparent}.bb-event-rects .bb-event-rect._active_{fill:rgba(39,201,3,.05)}.tick._active_ text{fill:#00c83c!important}.bb-grid{pointer-events:none}.bb-grid line{stroke:#f1f1f1}.bb-xgrid-focus line,.bb-ygrid-focus line{stroke:#ddd}.bb-text.bb-empty{fill:#767676}.bb-line{stroke-width:.7px}.bb-circle{fill:#fff!important}.bb-circle._expanded_{stroke-width:2px}.bb-selected-circle{fill:#fff;stroke-width:2px}.bb-bar{stroke-width:1px}.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;fill-opacity:.1}.bb-region.selected rect{fill:#27c903}.bb-brush .extent,.bb-zoom-brush{fill-opacity:.1}.bb-legend-item{user-select:none}.bb-legend-item line.bb-legend-item-tile{stroke-linecap:round;stroke-width:8px;stroke-dasharray:1 20;transform:translate(7px,1px)}.bb-legend-item-hidden{opacity:.15}.bb-legend-background{fill:#fff;stroke:#d3d3d3;stroke-width:1;opacity:.75}.bb-title{font-size:14px}.bb-chart-treemaps rect{stroke:#000;stroke-width:1px}.bb-tooltip-container{font-family:Sans Pro,Arial,sans-serif,nanumgothic,Dotum;user-select:none;z-index:10}.bb-tooltip{-webkit-font-smoothing:antialiased;background-color:#fff;border:1px solid #999;border-collapse:separate;border-radius:2px;border-spacing:0;empty-cells:show;font-size:11px;text-align:left;white-space:nowrap}.bb-tooltip th{background-color:#0b00b1;border-bottom:2px solid #ff2d2d;color:#fffdfd;font-size:13px;padding:2px 8px;text-align:left}.bb-tooltip td{padding:4px 6px}.bb-tooltip td:first-child{padding-left:8px}.bb-tooltip td:last-child{padding-right:8px}.bb-tooltip td>span,.bb-tooltip td>svg{border:1px solid #000;border-radius:3px;display:inline-block;height:8px;margin-right:6px;vertical-align:middle;width:8px}.bb-tooltip td.value{border-left:1px solid transparent;text-align:right}.bb-tooltip .bb-tooltip-title{color:#aaa;display:inline-block;line-height:20px}.bb-tooltip .bb-tooltip-detail table{border-collapse:collapse;border-spacing:0}.bb-tooltip .bb-tooltip-detail .bb-tooltip-name,.bb-tooltip .bb-tooltip-detail .bb-tooltip-value{color:#444;font-size:11px;font-weight:400;line-height:13px;padding:4px 0 3px;text-align:left}.bb-tooltip .bb-tooltip-detail .bb-tooltip-value{font-size:11px;font-weight:800;padding-left:5px}.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:none}.bb-chart-arcs .bb-chart-arcs-gauge-unit{fill:#000;font-size:18px}.bb-chart-arcs .bb-chart-arcs-gauge-max,.bb-chart-arcs .bb-chart-arcs-gauge-min{fill:#777}.bb-chart-arcs .bb-chart-arcs-title{fill:#000;font-size:18px!important;font-weight:600}.bb-chart-arcs path.empty{fill:#eaeaea;stroke-width:0}.bb-chart-arcs .bb-levels circle{fill:none;stroke:#848282;stroke-width:.5px}.bb-chart-arcs .bb-levels text{fill:#848282}.bb-line{shape-rendering:crispEdges}.bb-chart-arc .bb-gauge-value{fill:#3b6969}.bb-chart-arc path{stroke:#000;stroke-width:.5px}.bb-chart-arc rect{stroke:#fff;stroke-width:1}.bb-chart-arc text{fill:#fff;font-size:14px}.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:.7px}.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;padding:5px}
|
package/dist/theme/graph.css
CHANGED
package/dist/theme/graph.min.css
CHANGED
|
@@ -5,5 +5,5 @@
|
|
|
5
5
|
* billboard.js, JavaScript chart library
|
|
6
6
|
* https://naver.github.io/billboard.js/
|
|
7
7
|
*
|
|
8
|
-
* @version 3.9.
|
|
8
|
+
* @version 3.9.1
|
|
9
9
|
*/.bb-color-pattern{background-image:url(#65CFC2;#D0A45F;#64A4F5;#EF65A2;#A377FE;#8AAEC7;#FF7E5A;#898EFE;#FFAC35;#70B0FF;)}.bb svg{font-family:Helvetica,Apple SD Gothic Neo,Arial,sans-serif,nanumgothic,Dotum;font-size:12px;line-height:1}.bb line,.bb path{fill:none;stroke:#8c8c8c}.bb .bb-button,.bb text{fill:#555;font-size:12px;letter-spacing:-.3px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.bb-legend-item-title,.bb-xgrid-focus,.bb-ygrid,.bb-ygrid-focus{shape-rendering:crispEdges}.bb-chart-arcs .bb-needle{fill:#000}.bb-axis{shape-rendering:crispEdges}.bb-axis-y text,.bb-axis-y2 text{fill:#8c8c8c}.bb-event-rects{fill-opacity:1!important}.bb-event-rects .bb-event-rect{fill:transparent}.bb-event-rects .bb-event-rect._active_{fill:rgba(39,201,3,.05)}.tick._active_ text{fill:#00c83c!important}.bb-grid{pointer-events:none}.bb-grid line{stroke:#f1f1f1}.bb-xgrid-focus line,.bb-ygrid-focus line{stroke:#ffb6b6;stroke-dasharray:3px}.bb-text.bb-empty{fill:#767676}.bb-line{stroke-width:1px}.bb-circle._expanded_,rect.bb-circle._expanded_,use.bb-circle._expanded_{stroke-width:2px}.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;fill-opacity:.1}.bb-region.selected rect{fill:#27c903}.bb-brush .extent,.bb-zoom-brush{fill-opacity:.1}.bb-legend-item{user-select:none}.bb-legend-item-hidden{opacity:.15}.bb-legend-background{fill:#fff;stroke:#d3d3d3;stroke-width:1px;opacity:.75}.bb-legend-item line{stroke-dasharray:1px}.bb-title{font-size:14px}.bb-chart-treemaps rect{stroke:#fff;stroke-width:1px}.bb-tooltip-container{font-family:Helvetica,Apple SD Gothic Neo,Arial,sans-serif,nanumgothic,Dotum;user-select:none;z-index:10}.bb-tooltip{background-color:#fff;border:1px solid #999;border-collapse:separate;border-radius:2px;border-spacing:0;box-shadow:.5px .5px 1px #999;empty-cells:show;font-size:12px;text-align:left;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;white-space:nowrap}.bb-tooltip th{background-color:#efefef;border-bottom:1px dotted #000;color:#000;font-size:12px;padding:4px 8px;text-align:center}.bb-tooltip tr:last-child td{border-bottom:none}.bb-tooltip td{background-color:#fff;border-bottom:1px solid #eee;padding:3px 6px}.bb-tooltip td:first-child{border-right:1px solid #eee;padding-left:5px}.bb-tooltip td:last-child{padding-right:5px}.bb-tooltip td>span,.bb-tooltip td>svg{display:inline-block;height:12px;margin-right:6px;vertical-align:middle;width:5px}.bb-tooltip td.value{border-left:1px solid transparent;text-align:right}.bb-tooltip .bb-tooltip-title{color:#aaa;display:inline-block;line-height:20px}.bb-tooltip .bb-tooltip-detail table{border-collapse:collapse;border-spacing:1px;font-size:12px}.bb-tooltip .bb-tooltip-detail .bb-tooltip-name,.bb-tooltip .bb-tooltip-detail .bb-tooltip-value{color:#444;font-weight:400;line-height:13px;padding:4px 0 3px;text-align:left}.bb-tooltip .bb-tooltip-detail .bb-tooltip-value{font-weight:800;padding-left:5px}.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-chart-arcs-title{fill:#8c8c8c;font-size:16px!important;font-style:italic}.bb-chart-arcs path.empty{fill:#eaeaea;stroke-width:0}.bb-chart-arcs .bb-levels circle{fill:none;stroke:#848282;stroke-width:.5px}.bb-chart-arcs .bb-levels text{fill:#848282}.bb-chart-arc .bb-gauge-value{fill:#8c8c8c;font-style:italic}.bb-chart-arc path{stroke:#fff}.bb-chart-arc rect{stroke:#fff;stroke-width:1}.bb-chart-arc text{fill:#fff;font-size:13px;font-weight:700}.bb-chart-radars .bb-levels polygon{fill:none;stroke:#8c8c8c;stroke-width:.5px}.bb-chart-radars .bb-levels text{fill:#8c8c8c}.bb-chart-radars .bb-axis line{stroke:#8c8c8c;stroke-width:.5px}.bb-chart-radars .bb-axis text{cursor:default;font-size:1.15em;font-weight:700}.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;box-shadow:1px 1px 2px #ccc;cursor:pointer;opacity:.8;padding:5px}
|
package/dist/theme/insight.css
CHANGED
|
@@ -5,5 +5,5 @@
|
|
|
5
5
|
* billboard.js, JavaScript chart library
|
|
6
6
|
* https://naver.github.io/billboard.js/
|
|
7
7
|
*
|
|
8
|
-
* @version 3.9.
|
|
8
|
+
* @version 3.9.1
|
|
9
9
|
*/.bb-color-pattern{background-image:url(#00c73c;#fa7171;#2ad0ff;#7294ce;#e3e448;#cc7e6e;#fb6ccf;#c98dff;#4aea99;#bbbbbb;)}.bb svg{font-family:sans-serif,Arial,nanumgothic,Dotum;font-size:12px;line-height:1}.bb line,.bb path{fill:none;stroke:#c4c4c4}.bb .bb-button,.bb text{fill:#555;font-size:11px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.bb-legend-item-title,.bb-xgrid-focus,.bb-ygrid,.bb-ygrid-focus{shape-rendering:crispEdges}.bb-chart-arcs .bb-needle{fill:#000}.bb-axis{shape-rendering:crispEdges}.bb-axis-y text,.bb-axis-y2 text{fill:#737373}.bb-event-rects{fill-opacity:1!important}.bb-event-rects .bb-event-rect{fill:transparent}.bb-event-rects .bb-event-rect._active_{fill:rgba(39,201,3,.05)}.tick._active_ text{fill:#00c83c!important}.bb-grid{pointer-events:none}.bb-grid line{stroke:#f1f1f1}.bb-xgrid-focus line,.bb-ygrid-focus line{stroke:#ddd}.bb-text.bb-empty{fill:#767676}.bb-line{stroke-width:1px}.bb-circle._expanded_{fill:#fff!important;stroke-width:2px;stroke:red}rect.bb-circle._expanded_,use.bb-circle._expanded_{stroke-width:1px}.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;fill-opacity:.1}.bb-region.selected rect{fill:#27c903}.bb-brush .extent,.bb-zoom-brush{fill-opacity:.1}.bb-legend-item{user-select:none}.bb-legend-item-hidden{opacity:.15}.bb-legend-background{fill:#fff;stroke:#d3d3d3;stroke-width:1;opacity:.75}.bb-title{font-size:14px}.bb-chart-treemaps rect{stroke:#fff;stroke-width:1px}.bb-tooltip-container{font-family:sans-serif,Arial,nanumgothic,Dotum;user-select:none;z-index:10}.bb-tooltip{background-color:#fff;border:1px solid #999;border-collapse:separate;border-spacing:0;empty-cells:show;font-size:11px;text-align:left;white-space:nowrap}.bb-tooltip th{border-bottom:1px solid #eee;font-size:12px;padding:4px 8px;text-align:left}.bb-tooltip td{background-color:#fff;padding:4px 6px}.bb-tooltip td:first-child{padding-left:8px}.bb-tooltip td:last-child{padding-right:8px}.bb-tooltip td>span,.bb-tooltip td>svg{border-radius:5px;display:inline-block;height:10px;margin-right:6px;vertical-align:middle;width:10px}.bb-tooltip td.value{border-left:1px solid transparent}.bb-tooltip .bb-tooltip-title{color:#aaa;display:inline-block;line-height:20px}.bb-tooltip .bb-tooltip-detail table{border-collapse:collapse;border-spacing:0}.bb-tooltip .bb-tooltip-detail .bb-tooltip-name,.bb-tooltip .bb-tooltip-detail .bb-tooltip-value{color:#444;font-size:11px;font-weight:400;line-height:13px;padding:4px 0 3px;text-align:left}.bb-tooltip .bb-tooltip-detail .bb-tooltip-value{font-size:12px;font-weight:800;padding-left:5px}.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:none}.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-chart-arcs-title{fill:#000;font-size:16px!important;font-weight:600}.bb-chart-arcs path.empty{fill:#eaeaea;stroke-width:0}.bb-chart-arcs .bb-levels circle{fill:none;stroke:#848282;stroke-width:.5px}.bb-chart-arcs .bb-levels text{fill:#848282}.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-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;padding:5px}
|
package/dist-esm/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.9.
|
|
8
|
+
* @version 3.9.1
|
|
9
9
|
*/
|
|
10
10
|
import { timeParse, utcParse, timeFormat, utcFormat } from 'd3-time-format';
|
|
11
11
|
import { pointer, select, namespaces, selectAll } from 'd3-selection';
|
|
@@ -4349,18 +4349,8 @@ var data$1 = {
|
|
|
4349
4349
|
},
|
|
4350
4350
|
findClosest: function (values, pos) {
|
|
4351
4351
|
var $$ = this;
|
|
4352
|
-
var
|
|
4352
|
+
var main = $$.$el.main;
|
|
4353
4353
|
var data = values.filter(function (v) { return v && isValue(v.value); });
|
|
4354
|
-
var getSensitivity = function (d) {
|
|
4355
|
-
var sensitivity = config.point_sensitivity;
|
|
4356
|
-
if (isFunction(sensitivity)) {
|
|
4357
|
-
sensitivity = sensitivity.call($$.api, d);
|
|
4358
|
-
}
|
|
4359
|
-
else if (sensitivity === "radius") {
|
|
4360
|
-
sensitivity = d.r;
|
|
4361
|
-
}
|
|
4362
|
-
return sensitivity;
|
|
4363
|
-
};
|
|
4364
4354
|
var minDist;
|
|
4365
4355
|
var closest;
|
|
4366
4356
|
// find mouseovering bar/candlestick
|
|
@@ -4380,7 +4370,7 @@ var data$1 = {
|
|
|
4380
4370
|
.filter(function (v) { return !$$.isBarType(v.id) && !$$.isCandlestickType(v.id); })
|
|
4381
4371
|
.forEach(function (v) {
|
|
4382
4372
|
var d = $$.dist(v, pos);
|
|
4383
|
-
minDist =
|
|
4373
|
+
minDist = $$.getPointSensitivity(v);
|
|
4384
4374
|
if (d < minDist) {
|
|
4385
4375
|
minDist = d;
|
|
4386
4376
|
closest = v;
|
|
@@ -8513,19 +8503,49 @@ var tooltip$1 = {
|
|
|
8513
8503
|
.replace(/(\r?\n|\t)/g, "")
|
|
8514
8504
|
.split(/{{(.*)}}/);
|
|
8515
8505
|
},
|
|
8506
|
+
/**
|
|
8507
|
+
* Update tooltip position coordinate
|
|
8508
|
+
* @param {object} dataToShow Data object
|
|
8509
|
+
* @param {SVGElement} eventTarget Event element
|
|
8510
|
+
* @private
|
|
8511
|
+
*/
|
|
8512
|
+
setTooltipPosition: function (dataToShow, eventTarget) {
|
|
8513
|
+
var _a, _b;
|
|
8514
|
+
var $$ = this;
|
|
8515
|
+
var config = $$.config, scale = $$.scale, state = $$.state, _c = $$.$el, eventRect = _c.eventRect, tooltip = _c.tooltip;
|
|
8516
|
+
var bindto = config.tooltip_contents.bindto;
|
|
8517
|
+
var datum = tooltip.datum();
|
|
8518
|
+
if (!bindto && datum) {
|
|
8519
|
+
var _d = getPointer(state.event, eventTarget !== null && eventTarget !== void 0 ? eventTarget : eventRect.node()), x = _d[0], y = _d[1]; // get mouse event position
|
|
8520
|
+
var currPos = { x: x, y: y };
|
|
8521
|
+
if (scale.x && datum && "x" in datum) {
|
|
8522
|
+
currPos.xAxis = scale.x(datum.x);
|
|
8523
|
+
}
|
|
8524
|
+
var _e = datum.width, width = _e === void 0 ? 0 : _e, _f = datum.height, height = _f === void 0 ? 0 : _f;
|
|
8525
|
+
// Get tooltip position
|
|
8526
|
+
var pos_1 = (_b = (_a = config.tooltip_position) === null || _a === void 0 ? void 0 : _a.bind($$.api)(dataToShow !== null && dataToShow !== void 0 ? dataToShow : JSON.parse(datum.current), width, height, eventRect === null || eventRect === void 0 ? void 0 : eventRect.node(), currPos)) !== null && _b !== void 0 ? _b : $$.getTooltipPosition.bind($$)(width, height, currPos);
|
|
8527
|
+
["top", "left"].forEach(function (v) {
|
|
8528
|
+
var value = pos_1[v];
|
|
8529
|
+
tooltip.style(v, "".concat(value, "px"));
|
|
8530
|
+
// Remember left pos in percentage to be used on resize call
|
|
8531
|
+
if (v === "left" && !datum.xPosInPercent) {
|
|
8532
|
+
datum.xPosInPercent = value / state.current.width * 100;
|
|
8533
|
+
}
|
|
8534
|
+
});
|
|
8535
|
+
}
|
|
8536
|
+
},
|
|
8516
8537
|
/**
|
|
8517
8538
|
* Returns the position of the tooltip
|
|
8518
|
-
* @param {object} dataToShow data
|
|
8519
8539
|
* @param {string} tWidth Width value of tooltip element
|
|
8520
8540
|
* @param {string} tHeight Height value of tooltip element
|
|
8521
|
-
* @param {
|
|
8541
|
+
* @param {object} currPos Current mouse position
|
|
8522
8542
|
* @returns {object} top, left value
|
|
8523
8543
|
* @private
|
|
8524
8544
|
*/
|
|
8525
|
-
|
|
8545
|
+
getTooltipPosition: function (tWidth, tHeight, currPos) {
|
|
8526
8546
|
var $$ = this;
|
|
8527
8547
|
var config = $$.config, scale = $$.scale, state = $$.state;
|
|
8528
|
-
var width = state.width, height = state.height, current = state.current, isLegendRight = state.isLegendRight, inputType = state.inputType
|
|
8548
|
+
var width = state.width, height = state.height, current = state.current, isLegendRight = state.isLegendRight, inputType = state.inputType;
|
|
8529
8549
|
var hasGauge = $$.hasType("gauge") && !config.gauge_fullCircle;
|
|
8530
8550
|
var hasTreemap = state.hasTreemap;
|
|
8531
8551
|
var isRotated = config.axis_rotated;
|
|
@@ -8533,7 +8553,7 @@ var tooltip$1 = {
|
|
|
8533
8553
|
var chartRight = svgLeft + current.width - $$.getCurrentPaddingRight();
|
|
8534
8554
|
var chartLeft = $$.getCurrentPaddingLeft(true);
|
|
8535
8555
|
var size = 20;
|
|
8536
|
-
var
|
|
8556
|
+
var x = currPos.x, y = currPos.y;
|
|
8537
8557
|
// Determine tooltip position
|
|
8538
8558
|
if ($$.hasArcType()) {
|
|
8539
8559
|
var raw = inputType === "touch" || $$.hasType("radar");
|
|
@@ -8543,15 +8563,14 @@ var tooltip$1 = {
|
|
|
8543
8563
|
}
|
|
8544
8564
|
}
|
|
8545
8565
|
else if (!hasTreemap) {
|
|
8546
|
-
var dataScale = scale.x(dataToShow[0].x);
|
|
8547
8566
|
if (isRotated) {
|
|
8548
|
-
y =
|
|
8567
|
+
y = currPos.xAxis + size;
|
|
8549
8568
|
x += svgLeft;
|
|
8550
8569
|
chartRight -= svgLeft;
|
|
8551
8570
|
}
|
|
8552
8571
|
else {
|
|
8553
8572
|
y -= 5;
|
|
8554
|
-
x = svgLeft + chartLeft + size + (scale.zoom ? x :
|
|
8573
|
+
x = svgLeft + chartLeft + size + (scale.zoom ? x : currPos.xAxis);
|
|
8555
8574
|
}
|
|
8556
8575
|
}
|
|
8557
8576
|
// when tooltip left + tWidth > chart's width
|
|
@@ -8574,23 +8593,20 @@ var tooltip$1 = {
|
|
|
8574
8593
|
/**
|
|
8575
8594
|
* Show the tooltip
|
|
8576
8595
|
* @param {object} selectedData Data object
|
|
8577
|
-
* @param {SVGElement}
|
|
8596
|
+
* @param {SVGElement} eventTarget Event element
|
|
8578
8597
|
* @private
|
|
8579
8598
|
*/
|
|
8580
|
-
showTooltip: function (selectedData,
|
|
8581
|
-
var _a, _b;
|
|
8599
|
+
showTooltip: function (selectedData, eventTarget) {
|
|
8582
8600
|
var $$ = this;
|
|
8583
|
-
var config = $$.config,
|
|
8584
|
-
var bindto = config.tooltip_contents.bindto;
|
|
8601
|
+
var config = $$.config, tooltip = $$.$el.tooltip;
|
|
8585
8602
|
var dataToShow = selectedData.filter(function (d) { return d && isValue($$.getBaseValue(d)); });
|
|
8586
8603
|
if (!tooltip || dataToShow.length === 0 || !config.tooltip_show) {
|
|
8587
8604
|
return;
|
|
8588
8605
|
}
|
|
8589
8606
|
var datum = tooltip.datum();
|
|
8590
|
-
var _c = datum || {}, _d = _c.width, width = _d === void 0 ? 0 : _d, _e = _c.height, height = _e === void 0 ? 0 : _e;
|
|
8591
8607
|
var dataStr = JSON.stringify(selectedData);
|
|
8592
8608
|
if (!datum || datum.current !== dataStr) {
|
|
8593
|
-
var
|
|
8609
|
+
var _a = selectedData.concat().sort()[0], index = _a.index, x = _a.x;
|
|
8594
8610
|
callFn(config.tooltip_onshow, $$.api, selectedData);
|
|
8595
8611
|
// set tooltip content
|
|
8596
8612
|
tooltip
|
|
@@ -8603,32 +8619,15 @@ var tooltip$1 = {
|
|
|
8603
8619
|
.style("visibility", null) // for IE9
|
|
8604
8620
|
.datum(datum = {
|
|
8605
8621
|
index: index,
|
|
8622
|
+
x: x,
|
|
8606
8623
|
current: dataStr,
|
|
8607
|
-
width:
|
|
8608
|
-
height:
|
|
8624
|
+
width: tooltip.property("offsetWidth"),
|
|
8625
|
+
height: tooltip.property("offsetHeight")
|
|
8609
8626
|
});
|
|
8610
8627
|
callFn(config.tooltip_onshown, $$.api, selectedData);
|
|
8611
8628
|
$$._handleLinkedCharts(true, index);
|
|
8612
8629
|
}
|
|
8613
|
-
|
|
8614
|
-
var fnPos = ((_a = config.tooltip_position) === null || _a === void 0 ? void 0 : _a.bind($$.api)) || $$.tooltipPosition.bind($$);
|
|
8615
|
-
var _f = getPointer(state.event, eventRect), x = _f[0], y = _f[1]; // get mouse event position
|
|
8616
|
-
var currPos = { x: x, y: y };
|
|
8617
|
-
var data = (_b = selectedData.filter(Boolean)) === null || _b === void 0 ? void 0 : _b.shift();
|
|
8618
|
-
if (scale.x && data && "x" in data) {
|
|
8619
|
-
currPos.xAxis = scale.x(data.x);
|
|
8620
|
-
}
|
|
8621
|
-
// Get tooltip dimensions
|
|
8622
|
-
var pos_1 = fnPos(dataToShow, width, height, eventRect, currPos);
|
|
8623
|
-
["top", "left"].forEach(function (v) {
|
|
8624
|
-
var value = pos_1[v];
|
|
8625
|
-
tooltip.style(v, "".concat(value, "px"));
|
|
8626
|
-
// Remember left pos in percentage to be used on resize call
|
|
8627
|
-
if (v === "left" && !datum.xPosInPercent) {
|
|
8628
|
-
datum.xPosInPercent = value / state.current.width * 100;
|
|
8629
|
-
}
|
|
8630
|
-
});
|
|
8631
|
-
}
|
|
8630
|
+
$$.setTooltipPosition(dataToShow, eventTarget);
|
|
8632
8631
|
},
|
|
8633
8632
|
/**
|
|
8634
8633
|
* Adjust tooltip position on resize event
|
|
@@ -13631,8 +13630,9 @@ var eventrect = {
|
|
|
13631
13630
|
$$.setExpand(closest.index, closest.id, true);
|
|
13632
13631
|
// Show xgrid focus line
|
|
13633
13632
|
$$.showGridFocus(selectedData);
|
|
13633
|
+
var dist = $$.dist(closest, mouse);
|
|
13634
13634
|
// Show cursor as pointer if point is close to mouse position
|
|
13635
|
-
if ($$.isBarType(closest.id) ||
|
|
13635
|
+
if ($$.isBarType(closest.id) || dist < $$.getPointSensitivity(closest)) {
|
|
13636
13636
|
$$.$el.svg.select(".".concat($EVENT.eventRect)).style("cursor", "pointer");
|
|
13637
13637
|
if (!state.mouseover) {
|
|
13638
13638
|
config.data_onover.call($$.api, closest);
|
|
@@ -13706,9 +13706,10 @@ var eventrect = {
|
|
|
13706
13706
|
index += 1;
|
|
13707
13707
|
}
|
|
13708
13708
|
}
|
|
13709
|
+
var eventOnSameIdx = config.tooltip_grouped && index === eventReceiver.currentIdx;
|
|
13709
13710
|
// do nothing while dragging/flowing
|
|
13710
|
-
if (state.dragging || state.flowing || $$.hasArcType() ||
|
|
13711
|
-
|
|
13711
|
+
if (state.dragging || state.flowing || $$.hasArcType() || eventOnSameIdx) {
|
|
13712
|
+
eventOnSameIdx && $$.setTooltipPosition();
|
|
13712
13713
|
return;
|
|
13713
13714
|
}
|
|
13714
13715
|
if (index !== eventReceiver.currentIdx) {
|
|
@@ -18883,6 +18884,22 @@ var shapePoint = {
|
|
|
18883
18884
|
}
|
|
18884
18885
|
return Math.sqrt(Math.pow(cx - mouse[0], 2) + Math.pow(cy - mouse[1], 2)) < (r || this.config.point_sensitivity);
|
|
18885
18886
|
},
|
|
18887
|
+
/**
|
|
18888
|
+
* Get data point sensitivity radius
|
|
18889
|
+
* @param {object} d Data point object
|
|
18890
|
+
* @returns {number} return the sensitivity value
|
|
18891
|
+
*/
|
|
18892
|
+
getPointSensitivity: function (d) {
|
|
18893
|
+
var $$ = this;
|
|
18894
|
+
var sensitivity = $$.config.point_sensitivity;
|
|
18895
|
+
if (isFunction(sensitivity)) {
|
|
18896
|
+
sensitivity = sensitivity.call($$.api, d);
|
|
18897
|
+
}
|
|
18898
|
+
else if (sensitivity === "radius") {
|
|
18899
|
+
sensitivity = d.r;
|
|
18900
|
+
}
|
|
18901
|
+
return sensitivity;
|
|
18902
|
+
},
|
|
18886
18903
|
insertPointInfoDefs: function (point, id) {
|
|
18887
18904
|
var _a;
|
|
18888
18905
|
var $$ = this;
|
|
@@ -22635,7 +22652,7 @@ var zoomModule = function () {
|
|
|
22635
22652
|
var defaults = {};
|
|
22636
22653
|
/**
|
|
22637
22654
|
* @namespace bb
|
|
22638
|
-
* @version 3.9.
|
|
22655
|
+
* @version 3.9.1
|
|
22639
22656
|
*/
|
|
22640
22657
|
var bb = {
|
|
22641
22658
|
/**
|
|
@@ -22645,7 +22662,7 @@ var bb = {
|
|
|
22645
22662
|
* bb.version; // "1.0.0"
|
|
22646
22663
|
* @memberof bb
|
|
22647
22664
|
*/
|
|
22648
|
-
version: "3.9.
|
|
22665
|
+
version: "3.9.1",
|
|
22649
22666
|
/**
|
|
22650
22667
|
* Generate chart
|
|
22651
22668
|
* - **NOTE:** Bear in mind for the possiblity of ***throwing an error***, during the generation when:
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* billboard.js, JavaScript chart library
|
|
6
6
|
* https://naver.github.io/billboard.js/
|
|
7
7
|
*
|
|
8
|
-
* @version 3.9.
|
|
8
|
+
* @version 3.9.1
|
|
9
9
|
* @requires billboard.js
|
|
10
10
|
* @summary billboard.js plugin
|
|
11
11
|
*/
|
|
@@ -104,7 +104,7 @@ var Plugin = /** @class */ (function () {
|
|
|
104
104
|
delete _this[key];
|
|
105
105
|
});
|
|
106
106
|
};
|
|
107
|
-
Plugin.version = "3.9.
|
|
107
|
+
Plugin.version = "3.9.1";
|
|
108
108
|
return Plugin;
|
|
109
109
|
}());
|
|
110
110
|
var Plugin$1 = Plugin;
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* billboard.js, JavaScript chart library
|
|
6
6
|
* https://naver.github.io/billboard.js/
|
|
7
7
|
*
|
|
8
|
-
* @version 3.9.
|
|
8
|
+
* @version 3.9.1
|
|
9
9
|
* @requires billboard.js
|
|
10
10
|
* @summary billboard.js plugin
|
|
11
11
|
*/
|
|
@@ -279,7 +279,7 @@ var Plugin = /** @class */ (function () {
|
|
|
279
279
|
delete _this[key];
|
|
280
280
|
});
|
|
281
281
|
};
|
|
282
|
-
Plugin.version = "3.9.
|
|
282
|
+
Plugin.version = "3.9.1";
|
|
283
283
|
return Plugin;
|
|
284
284
|
}());
|
|
285
285
|
var Plugin$1 = Plugin;
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* billboard.js, JavaScript chart library
|
|
6
6
|
* https://naver.github.io/billboard.js/
|
|
7
7
|
*
|
|
8
|
-
* @version 3.9.
|
|
8
|
+
* @version 3.9.1
|
|
9
9
|
* @requires billboard.js
|
|
10
10
|
* @summary billboard.js plugin
|
|
11
11
|
*/
|
|
@@ -487,7 +487,7 @@ var Plugin = /** @class */ (function () {
|
|
|
487
487
|
delete _this[key];
|
|
488
488
|
});
|
|
489
489
|
};
|
|
490
|
-
Plugin.version = "3.9.
|
|
490
|
+
Plugin.version = "3.9.1";
|
|
491
491
|
return Plugin;
|
|
492
492
|
}());
|
|
493
493
|
var Plugin$1 = Plugin;
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* billboard.js, JavaScript chart library
|
|
6
6
|
* https://naver.github.io/billboard.js/
|
|
7
7
|
*
|
|
8
|
-
* @version 3.9.
|
|
8
|
+
* @version 3.9.1
|
|
9
9
|
* @requires billboard.js
|
|
10
10
|
* @summary billboard.js plugin
|
|
11
11
|
*/
|
|
@@ -121,7 +121,7 @@ var Plugin = /** @class */ (function () {
|
|
|
121
121
|
delete _this[key];
|
|
122
122
|
});
|
|
123
123
|
};
|
|
124
|
-
Plugin.version = "3.9.
|
|
124
|
+
Plugin.version = "3.9.1";
|
|
125
125
|
return Plugin;
|
|
126
126
|
}());
|
|
127
127
|
var Plugin$1 = Plugin;
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* billboard.js, JavaScript chart library
|
|
6
6
|
* https://naver.github.io/billboard.js/
|
|
7
7
|
*
|
|
8
|
-
* @version 3.9.
|
|
8
|
+
* @version 3.9.1
|
|
9
9
|
* @requires billboard.js
|
|
10
10
|
* @summary billboard.js plugin
|
|
11
11
|
*/
|
|
@@ -263,7 +263,7 @@ var Plugin = /** @class */ (function () {
|
|
|
263
263
|
delete _this[key];
|
|
264
264
|
});
|
|
265
265
|
};
|
|
266
|
-
Plugin.version = "3.9.
|
|
266
|
+
Plugin.version = "3.9.1";
|
|
267
267
|
return Plugin;
|
|
268
268
|
}());
|
|
269
269
|
var Plugin$1 = Plugin;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "billboard.js",
|
|
3
|
-
"version": "3.9.
|
|
3
|
+
"version": "3.9.1",
|
|
4
4
|
"description": "Re-usable easy interface JavaScript chart library, based on D3 v4+",
|
|
5
5
|
"homepage": "https://naver.github.io/billboard.js/",
|
|
6
6
|
"main": "dist/billboard.js",
|
|
@@ -102,34 +102,34 @@
|
|
|
102
102
|
"d3-zoom": "^3.0.0"
|
|
103
103
|
},
|
|
104
104
|
"devDependencies": {
|
|
105
|
-
"@babel/core": "^7.22.
|
|
106
|
-
"@babel/eslint-parser": "^7.22.
|
|
105
|
+
"@babel/core": "^7.22.8",
|
|
106
|
+
"@babel/eslint-parser": "^7.22.7",
|
|
107
107
|
"@babel/plugin-proposal-class-properties": "^7.18.6",
|
|
108
108
|
"@babel/plugin-proposal-object-rest-spread": "^7.20.7",
|
|
109
|
-
"@babel/plugin-transform-runtime": "^7.22.
|
|
110
|
-
"@babel/preset-env": "^7.22.
|
|
109
|
+
"@babel/plugin-transform-runtime": "^7.22.7",
|
|
110
|
+
"@babel/preset-env": "^7.22.7",
|
|
111
111
|
"@babel/preset-typescript": "^7.22.5",
|
|
112
|
-
"@babel/runtime": "^7.22.
|
|
113
|
-
"@commitlint/cli": "17.6.
|
|
114
|
-
"@commitlint/config-conventional": "^17.6.
|
|
112
|
+
"@babel/runtime": "^7.22.6",
|
|
113
|
+
"@commitlint/cli": "17.6.6",
|
|
114
|
+
"@commitlint/config-conventional": "^17.6.6",
|
|
115
115
|
"@rollup/plugin-babel": "^6.0.3",
|
|
116
116
|
"@rollup/plugin-node-resolve": "^15.0.2",
|
|
117
117
|
"@rollup/plugin-replace": "^5.0.2",
|
|
118
|
-
"@rollup/plugin-typescript": "^11.1.
|
|
118
|
+
"@rollup/plugin-typescript": "^11.1.2",
|
|
119
119
|
"@semantic-release/changelog": "^6.0.3",
|
|
120
120
|
"@semantic-release/commit-analyzer": "^10.0.1",
|
|
121
121
|
"@semantic-release/exec": "^6.0.3",
|
|
122
122
|
"@semantic-release/git": "^10.0.1",
|
|
123
123
|
"@semantic-release/npm": "^10.0.4",
|
|
124
|
-
"@semantic-release/release-notes-generator": "^11.0.
|
|
124
|
+
"@semantic-release/release-notes-generator": "^11.0.4",
|
|
125
125
|
"@types/chai": "^4.3.5",
|
|
126
126
|
"@types/d3": "^7.4.0",
|
|
127
127
|
"@types/mocha": "^10.0.1",
|
|
128
128
|
"@types/sinon": "^10.0.15",
|
|
129
|
-
"@typescript-eslint/eslint-plugin": "^
|
|
130
|
-
"@typescript-eslint/parser": "^
|
|
129
|
+
"@typescript-eslint/eslint-plugin": "^6.0.0",
|
|
130
|
+
"@typescript-eslint/parser": "^6.0.0",
|
|
131
131
|
"babel-helper-modules": "^6.0.0",
|
|
132
|
-
"babel-loader": "^9.1.
|
|
132
|
+
"babel-loader": "^9.1.3",
|
|
133
133
|
"babel-plugin-add-module-exports": "^1.0.4",
|
|
134
134
|
"babel-plugin-minify-constant-folding": "^0.5.0",
|
|
135
135
|
"babel-plugin-minify-dead-code-elimination": "^0.5.2",
|
|
@@ -143,7 +143,7 @@
|
|
|
143
143
|
"chai": "^4.3.7",
|
|
144
144
|
"clean-webpack-plugin": "^4.0.0",
|
|
145
145
|
"cloc": "^2.11.0",
|
|
146
|
-
"core-js": "^3.31.
|
|
146
|
+
"core-js": "^3.31.1",
|
|
147
147
|
"coveralls": "^3.1.1",
|
|
148
148
|
"cross-env": "^7.0.3",
|
|
149
149
|
"css-loader": "^6.8.1",
|
|
@@ -154,10 +154,10 @@
|
|
|
154
154
|
"d3-polygon": "^3.0.1",
|
|
155
155
|
"docdash": "^2.0.1",
|
|
156
156
|
"dtslint": "^4.2.1",
|
|
157
|
-
"eslint": "^8.
|
|
157
|
+
"eslint": "^8.44.0",
|
|
158
158
|
"eslint-config-naver": "^2.1.0",
|
|
159
159
|
"eslint-plugin-import": "^2.27.5",
|
|
160
|
-
"eslint-plugin-jsdoc": "^46.
|
|
160
|
+
"eslint-plugin-jsdoc": "^46.4.3",
|
|
161
161
|
"eslint-webpack-plugin": "^4.0.1",
|
|
162
162
|
"exports-loader": "^4.0.0",
|
|
163
163
|
"hammer-simulator": "0.0.1",
|
|
@@ -175,25 +175,25 @@
|
|
|
175
175
|
"karma-sinon": "^1.0.5",
|
|
176
176
|
"karma-sourcemap-loader": "^0.4.0",
|
|
177
177
|
"karma-webpack": "^5.0.0",
|
|
178
|
-
"lint-staged": "^13.2.
|
|
178
|
+
"lint-staged": "^13.2.3",
|
|
179
179
|
"lite-fixture": "^1.0.2",
|
|
180
180
|
"mini-css-extract-plugin": "^2.7.6",
|
|
181
181
|
"mocha": "^10.2.0",
|
|
182
182
|
"node-sass": "^9.0.0",
|
|
183
183
|
"regenerator-runtime": "^0.13.11",
|
|
184
|
-
"rollup": "^3.
|
|
184
|
+
"rollup": "^3.26.2",
|
|
185
185
|
"rollup-plugin-delete": "^2.0.0",
|
|
186
186
|
"sass-loader": "^13.3.2",
|
|
187
|
-
"semantic-release": "^21.0.
|
|
187
|
+
"semantic-release": "^21.0.7",
|
|
188
188
|
"simulant": "^0.2.2",
|
|
189
|
-
"sinon": "^15.
|
|
189
|
+
"sinon": "^15.2.0",
|
|
190
190
|
"string-replace-loader": "^3.1.0",
|
|
191
191
|
"style-loader": "^3.3.3",
|
|
192
192
|
"taffydb": "^2.7.3",
|
|
193
193
|
"terser-webpack-plugin": "^5.3.9",
|
|
194
|
-
"tslib": "^2.
|
|
195
|
-
"typescript": "5.1.
|
|
196
|
-
"webpack": "^5.
|
|
194
|
+
"tslib": "^2.6.0",
|
|
195
|
+
"typescript": "5.1.6",
|
|
196
|
+
"webpack": "^5.88.1",
|
|
197
197
|
"webpack-bundle-analyzer": "^4.9.0",
|
|
198
198
|
"webpack-clean": "^1.2.5",
|
|
199
199
|
"webpack-cli": "^5.1.4",
|
|
@@ -740,19 +740,9 @@ export default {
|
|
|
740
740
|
|
|
741
741
|
findClosest(values, pos: [number, number]): IDataRow | undefined {
|
|
742
742
|
const $$ = this;
|
|
743
|
-
const {
|
|
743
|
+
const {$el: {main}} = $$;
|
|
744
744
|
const data = values.filter(v => v && isValue(v.value));
|
|
745
|
-
const getSensitivity = (d: IDataPoint) => {
|
|
746
|
-
let sensitivity = config.point_sensitivity;
|
|
747
745
|
|
|
748
|
-
if (isFunction(sensitivity)) {
|
|
749
|
-
sensitivity = sensitivity.call($$.api, d);
|
|
750
|
-
} else if (sensitivity === "radius") {
|
|
751
|
-
sensitivity = d.r;
|
|
752
|
-
}
|
|
753
|
-
|
|
754
|
-
return sensitivity;
|
|
755
|
-
};
|
|
756
746
|
let minDist;
|
|
757
747
|
let closest;
|
|
758
748
|
|
|
@@ -776,7 +766,7 @@ export default {
|
|
|
776
766
|
.forEach((v: IDataPoint) => {
|
|
777
767
|
const d = $$.dist(v, pos);
|
|
778
768
|
|
|
779
|
-
minDist =
|
|
769
|
+
minDist = $$.getPointSensitivity(v);
|
|
780
770
|
|
|
781
771
|
if (d < minDist) {
|
|
782
772
|
minDist = d;
|
|
@@ -351,8 +351,10 @@ export default {
|
|
|
351
351
|
// Show xgrid focus line
|
|
352
352
|
$$.showGridFocus(selectedData);
|
|
353
353
|
|
|
354
|
+
const dist = $$.dist(closest, mouse);
|
|
355
|
+
|
|
354
356
|
// Show cursor as pointer if point is close to mouse position
|
|
355
|
-
if ($$.isBarType(closest.id) ||
|
|
357
|
+
if ($$.isBarType(closest.id) || dist < $$.getPointSensitivity(closest)) {
|
|
356
358
|
$$.$el.svg.select(`.${$EVENT.eventRect}`).style("cursor", "pointer");
|
|
357
359
|
|
|
358
360
|
if (!state.mouseover) {
|
|
@@ -445,10 +447,11 @@ export default {
|
|
|
445
447
|
}
|
|
446
448
|
}
|
|
447
449
|
|
|
450
|
+
const eventOnSameIdx = config.tooltip_grouped && index === eventReceiver.currentIdx;
|
|
451
|
+
|
|
448
452
|
// do nothing while dragging/flowing
|
|
449
|
-
if (state.dragging || state.flowing || $$.hasArcType() ||
|
|
450
|
-
|
|
451
|
-
) {
|
|
453
|
+
if (state.dragging || state.flowing || $$.hasArcType() || eventOnSameIdx) {
|
|
454
|
+
eventOnSameIdx && $$.setTooltipPosition();
|
|
452
455
|
return;
|
|
453
456
|
}
|
|
454
457
|
|