Skip to content

Commit

Permalink
Boxplot charts if boxpoints=false do not show custom tooltips
Browse files Browse the repository at this point in the history
  • Loading branch information
michelezanda committed Mar 27, 2018
1 parent 1a1db98 commit c00f451
Show file tree
Hide file tree
Showing 9 changed files with 59 additions and 58 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG_ION.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# plotly.js ION changelog

## [1.33.1-ion8] -- 2018-03-27

### Boxplot charts if boxpoints=false do not show custom tooltips.


## [1.33.1-ion7] -- 2018-03-26

### [ARCBUGS-4454] GUI throws unhandled exception intermittently when a user changes scatter chart to world chart. Due to bad params passed to map chart.
Expand Down
46 changes: 22 additions & 24 deletions dist_ion/plotly-ion.js
Original file line number Diff line number Diff line change
Expand Up @@ -32816,7 +32816,7 @@ exports.svgAttrs = {
var Plotly = require('./plotly');

// package version injected by `npm run preprocess`
exports.version = '1.33.1-ion7';
exports.version = '1.33.1-ion8';

// inject promise polyfill
require('es6-promise').polyfill();
Expand Down Expand Up @@ -64038,33 +64038,31 @@ function handlePointsDefaults(traceIn, traceOut, coerce, opts) {
(outlierColorDflt || lineoutliercolor) ? 'suspectedoutliers' : undefined
);

if(points) {
coerce('jitter', points === 'all' ? 0.3 : 0);
coerce('pointpos', points === 'all' ? -1.5 : 0);

coerce('marker.symbol');
coerce('marker.opacity');
coerce('marker.size');
coerce('marker.color', traceOut.line.color);
coerce('marker.line.color');
coerce('marker.line.width');
coerce('jitter', points === 'all' ? 0.3 : 0);
coerce('pointpos', points === 'all' ? -1.5 : 0);

if(points === 'suspectedoutliers') {
coerce('marker.line.outliercolor', traceOut.marker.color);
coerce('marker.line.outlierwidth');
}

coerce('selected.marker.color');
coerce('unselected.marker.color');
coerce('selected.marker.size');
coerce('unselected.marker.size');
coerce('marker.symbol');
coerce('marker.opacity');
coerce('marker.size');
coerce('marker.color', traceOut.line.color);
coerce('marker.line.color');
coerce('marker.line.width');

coerce('text');
coerce('textbox');
} else {
delete traceOut.marker;
if(points === 'suspectedoutliers') {
coerce('marker.line.outliercolor', traceOut.marker.color);
coerce('marker.line.outlierwidth');
}

coerce('selected.marker.color');
coerce('unselected.marker.color');
coerce('selected.marker.size');
coerce('unselected.marker.size');

coerce('text');
coerce('textbox');


coerce('hoveron');

Lib.coerceSelectionMarkerOpacity(traceOut, coerce);
Expand Down Expand Up @@ -64221,7 +64219,7 @@ function hoverOnBoxes(pointData, xval, yval, hovermode) {
if(trace.boxmean || (trace.meanline || {}).visible) {
attrs.push('mean');
}
if(trace.boxpoints || trace.points) {
if(trace.boxpoints) {
attrs.push('lf', 'uf');
}

Expand Down
2 changes: 1 addition & 1 deletion dist_ion/plotly-ion.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "plotly.js",
"version": "1.33.1-ion7",
"version": "1.33.1-ion8",
"description": "The open source javascript graphing library that powers plotly",
"license": "MIT",
"main": "./lib/index.js",
Expand Down
8 changes: 4 additions & 4 deletions samples/chart_perf.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
var trace1 = {
y: [2, 3, 4, 6,7, 8, 9, 10, 11, 12, 13],
//y: [-40, 50, 60],
//x: ['2017-01-04', '2017-01-05', '2017-01-06'],
y: [2, 3, 4, 6,7, 8, 9, 10, 11, 12, 13, 50],
// y: [-40, 50, 60],
// x: ['2017-01-04', '2017-01-05', '2017-01-06'],
// y: [-40, 50, 60],
close: [116.019997, 116.610001, 117.910004],

Expand All @@ -21,7 +21,7 @@ var trace1 = {

hoverinfo: 'text',

boxpoints: 'None',
boxpoints: false,
type: 'box',
name: 'MZ',
opacity: 0.5
Expand Down
2 changes: 1 addition & 1 deletion src/assets/geo_assets.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@ var saneTopojson = require('sane-topojson');


// package version injected by `npm run preprocess`
exports.version = '1.33.1-ion7';exports.topojson = saneTopojson;
exports.version = '1.33.1-ion8';exports.topojson = saneTopojson;
2 changes: 1 addition & 1 deletion src/core.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
var Plotly = require('./plotly');

// package version injected by `npm run preprocess`
exports.version = '1.33.1-ion7';
exports.version = '1.33.1-ion8';

// inject promise polyfill
require('es6-promise').polyfill();
Expand Down
48 changes: 23 additions & 25 deletions src/traces/box/defaults.js
Original file line number Diff line number Diff line change
Expand Up @@ -66,33 +66,31 @@ function handlePointsDefaults(traceIn, traceOut, coerce, opts) {
(outlierColorDflt || lineoutliercolor) ? 'suspectedoutliers' : undefined
);

if(points) {
coerce('jitter', points === 'all' ? 0.3 : 0);
coerce('pointpos', points === 'all' ? -1.5 : 0);

coerce('marker.symbol');
coerce('marker.opacity');
coerce('marker.size');
coerce('marker.color', traceOut.line.color);
coerce('marker.line.color');
coerce('marker.line.width');

if(points === 'suspectedoutliers') {
coerce('marker.line.outliercolor', traceOut.marker.color);
coerce('marker.line.outlierwidth');
}

coerce('selected.marker.color');
coerce('unselected.marker.color');
coerce('selected.marker.size');
coerce('unselected.marker.size');

coerce('text');
coerce('textbox');
} else {
delete traceOut.marker;

coerce('jitter', points === 'all' ? 0.3 : 0);
coerce('pointpos', points === 'all' ? -1.5 : 0);

coerce('marker.symbol');
coerce('marker.opacity');
coerce('marker.size');
coerce('marker.color', traceOut.line.color);
coerce('marker.line.color');
coerce('marker.line.width');

if(points === 'suspectedoutliers') {
coerce('marker.line.outliercolor', traceOut.marker.color);
coerce('marker.line.outlierwidth');
}

coerce('selected.marker.color');
coerce('unselected.marker.color');
coerce('selected.marker.size');
coerce('unselected.marker.size');

coerce('text');
coerce('textbox');


coerce('hoveron');

Lib.coerceSelectionMarkerOpacity(traceOut, coerce);
Expand Down
2 changes: 1 addition & 1 deletion src/traces/box/hover.js
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ function hoverOnBoxes(pointData, xval, yval, hovermode) {
if(trace.boxmean || (trace.meanline || {}).visible) {
attrs.push('mean');
}
if(trace.boxpoints || trace.points) {
if(trace.boxpoints) {
attrs.push('lf', 'uf');
}

Expand Down

0 comments on commit c00f451

Please sign in to comment.