Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP] Clean up chart layout code for improved maintainability #3837

Closed
10 changes: 10 additions & 0 deletions client/app/visualizations/chart/chart-editor.html
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,16 @@
</label>
</div>

<label class="control-label" for="legendOrientation">Legend orientation:</label>

<input type="radio" id="legendOrientationVertical"
name="legendOrientation" value="v" ng-model="$ctrl.options.legend.orientation">
<label for="contactChoice1">Vertical</label>

<input type="radio" id="legendOrientationHorizontal"
name="legendOrientation" value="h" ng-model="$ctrl.options.legend.orientation">
<label for="contactChoice2">Horizontal</label>

<div class="checkbox" ng-if="$ctrl.options.globalSeriesType == 'box'">
<label>
<input type="checkbox" ng-model="$ctrl.options.showpoints">
Expand Down
5 changes: 4 additions & 1 deletion client/app/visualizations/chart/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,10 @@ import editorTemplate from './chart-editor.html';
const DEFAULT_OPTIONS = {
globalSeriesType: 'column',
sortX: true,
legend: { enabled: true },
legend: {
enabled: true,
brylie marked this conversation as resolved.
Show resolved Hide resolved
orientation: 'v',
},
yAxis: [{ type: 'linear' }, { type: 'linear', opposite: true }],
xAxis: { type: '-', labels: { enabled: true } },
error_y: { type: 'data', visible: true },
Expand Down