Skip to content

Commit 9004b91

Browse files
author
Mischa Spelt
committed
Added property orders to ensure primary Y axis stays the default.
1 parent 3a75121 commit 9004b91

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

blazorbootstrap/Models/Charts/ChartOptions/ChartOptions.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -161,9 +161,11 @@ public class Scales
161161
#region Properties, Indexers
162162

163163
[JsonIgnore( Condition = JsonIgnoreCondition.WhenWritingNull )]
164+
[JsonPropertyOrder( 0 )]
164165
public ChartAxes? X { get; set; } = new();
165166

166167
[JsonIgnore( Condition = JsonIgnoreCondition.WhenWritingNull )]
168+
[JsonPropertyOrder( 1 )]
167169
public ChartAxes? Y { get; set; } = new();
168170

169171
#endregion

blazorbootstrap/Models/Charts/ChartOptions/LineChartScales.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
public class LineChartScales : Scales
44
{
55
[JsonIgnore( Condition = JsonIgnoreCondition.WhenWritingNull )]
6+
[JsonPropertyOrder( 2 )]
67
[JsonPropertyName( "Y1" )]
78
public ChartAxes? SecondaryY { get; set; } = new() { Display = false, Position = "right" };
89
}

0 commit comments

Comments
 (0)