We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent abcd729 commit 153f547Copy full SHA for 153f547
src/plots/cartesian/set_convert.js
@@ -148,8 +148,13 @@ module.exports = function setConvert(ax, fullLayout) {
148
// d2l/d2c variant that that won't add categories but will also
149
// allow numbers to be mapped to the linearized axis positions
150
var index;
151
- if(ax._categoriesMap) { index = ax._categoriesMap[v] ? ax._categoriesMap : undefined; }
152
- if(index !== undefined) { return index; }
+ if(ax._categoriesMap) {
+ index = ax._categoriesMap[v] ? ax._categoriesMap : undefined;
153
+ if(index !== undefined) return index;
154
+ } else {
155
+ index = ax._categories.indexOf(v);
156
+ if(index !== -1) return index;
157
+ }
158
if(typeof v === 'number') { return v; }
159
}
160
0 commit comments