Skip to content

Commit

Permalink
fix: add lx and ly for stacked plots
Browse files Browse the repository at this point in the history
  • Loading branch information
ellvix committed Aug 10, 2024
1 parent 1363d5c commit fe6db71
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/js/controls.js
Original file line number Diff line number Diff line change
Expand Up @@ -214,6 +214,12 @@ class Control {
singleMaidr.type.includes('point')
) {
xlabel = plot.x_group_label;
} else if (
singleMaidr.type == 'stacked_bar' ||
singleMaidr.type == 'stacked_normalized_bar' ||
singleMaidr.type == 'dodged_bar'
) {
xlabel = plot.plotLegend.x;
}
display.displayInfo('x label', xlabel);
pressedL = false;
Expand All @@ -232,6 +238,12 @@ class Control {
singleMaidr.type.includes('point')
) {
ylabel = plot.y_group_label;
} else if (
singleMaidr.type == 'stacked_bar' ||
singleMaidr.type == 'stacked_normalized_bar' ||
singleMaidr.type == 'dodged_bar'
) {
ylabel = plot.plotLegend.y;
}
display.displayInfo('y label', ylabel);
pressedL = false;
Expand Down

0 comments on commit fe6db71

Please sign in to comment.