Skip to content

Commit

Permalink
Merge pull request #421 from LayTec-AG/release/v4.3.0
Browse files Browse the repository at this point in the history
Release/v4.3.0
  • Loading branch information
sean-mcl authored Apr 8, 2024
2 parents 125c619 + 125b089 commit cf6320f
Show file tree
Hide file tree
Showing 11 changed files with 301 additions and 25 deletions.
28 changes: 14 additions & 14 deletions Directory.Packages.props
Original file line number Diff line number Diff line change
Expand Up @@ -12,21 +12,21 @@
<PackageVersion Include="Microsoft.CSharp" Version="4.7.0" />
</ItemGroup>
<ItemGroup>
<PackageVersion Condition="'$(TargetFramework)' == 'net6.0'" Include="Microsoft.AspNetCore.Components" Version="6.0.27" />
<PackageVersion Condition="'$(TargetFramework)' == 'net6.0'" Include="Microsoft.AspNetCore.Components.Web" Version="6.0.27" />
<PackageVersion Condition="'$(TargetFramework)' == 'net6.0'" Include="Microsoft.AspNetCore.Components.WebAssembly" Version="6.0.27" />
<PackageVersion Condition="'$(TargetFramework)' == 'net6.0'" Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="6.0.27" PrivateAssets="all" />
<PackageVersion Condition="'$(TargetFramework)' == 'net7.0'" Include="Microsoft.AspNetCore.Components" Version="7.0.16" />
<PackageVersion Condition="'$(TargetFramework)' == 'net7.0'" Include="Microsoft.AspNetCore.Components.Web" Version="7.0.16" />
<PackageVersion Condition="'$(TargetFramework)' == 'net7.0'" Include="Microsoft.AspNetCore.Components.WebAssembly" Version="7.0.16" />
<PackageVersion Condition="'$(TargetFramework)' == 'net7.0'" Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="7.0.16" PrivateAssets="all" />
<PackageVersion Condition="'$(TargetFramework)' == 'net8.0'" Include="Microsoft.AspNetCore.Components" Version="8.0.2" />
<PackageVersion Condition="'$(TargetFramework)' == 'net8.0'" Include="Microsoft.AspNetCore.Components.Web" Version="8.0.2" />
<PackageVersion Condition="'$(TargetFramework)' == 'net8.0'" Include="Microsoft.AspNetCore.Components.WebAssembly" Version="8.0.2" />
<PackageVersion Condition="'$(TargetFramework)' == 'net8.0'" Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="8.0.2" PrivateAssets="all" />
<PackageVersion Include="MudBlazor" Version="6.11.1" />
<PackageVersion Condition="'$(TargetFramework)' == 'net6.0'" Include="Microsoft.AspNetCore.Components" Version="6.0.28" />
<PackageVersion Condition="'$(TargetFramework)' == 'net6.0'" Include="Microsoft.AspNetCore.Components.Web" Version="6.0.28" />
<PackageVersion Condition="'$(TargetFramework)' == 'net6.0'" Include="Microsoft.AspNetCore.Components.WebAssembly" Version="6.0.28" />
<PackageVersion Condition="'$(TargetFramework)' == 'net6.0'" Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="6.0.28" PrivateAssets="all" />
<PackageVersion Condition="'$(TargetFramework)' == 'net7.0'" Include="Microsoft.AspNetCore.Components" Version="7.0.17" />
<PackageVersion Condition="'$(TargetFramework)' == 'net7.0'" Include="Microsoft.AspNetCore.Components.Web" Version="7.0.17" />
<PackageVersion Condition="'$(TargetFramework)' == 'net7.0'" Include="Microsoft.AspNetCore.Components.WebAssembly" Version="7.0.17" />
<PackageVersion Condition="'$(TargetFramework)' == 'net7.0'" Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="7.0.17" PrivateAssets="all" />
<PackageVersion Condition="'$(TargetFramework)' == 'net8.0'" Include="Microsoft.AspNetCore.Components" Version="8.0.3" />
<PackageVersion Condition="'$(TargetFramework)' == 'net8.0'" Include="Microsoft.AspNetCore.Components.Web" Version="8.0.3" />
<PackageVersion Condition="'$(TargetFramework)' == 'net8.0'" Include="Microsoft.AspNetCore.Components.WebAssembly" Version="8.0.3" />
<PackageVersion Condition="'$(TargetFramework)' == 'net8.0'" Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="8.0.3" PrivateAssets="all" />
<PackageVersion Include="MudBlazor" Version="6.19.1" />
<PackageVersion Include="Newtonsoft.Json" Version="13.0.3" />
<PackageVersion Include="PublishSPAforGitHubPages.Build" Version="2.1.0" />
<PackageVersion Include="PublishSPAforGitHubPages.Build" Version="2.1.1" />
<PackageVersion Include="Stubble.Core" Version="1.10.8" />
<PackageVersion Include="WeCantSpell.Hunspell" Version="5.0.0" />
<PackageVersion Include="FluentAssertions" Version="6.12.0" />
Expand Down
2 changes: 1 addition & 1 deletion Plotly.Blazor.Generator/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ namespace Plotly.Blazor.Generator
internal class Program
{
private const string NAMESPACE = "Plotly.Blazor";
private const string PLOTLY_JS_URL = "https://cdn.plot.ly/plotly-2.29.1.min.js";
private const string PLOTLY_JS_URL = "https://cdn.plot.ly/plotly-2.30.1.min.js";

private static SchemaRoot _schema;
private static StubbleVisitorRenderer _stubble;
Expand Down
2 changes: 1 addition & 1 deletion Plotly.Blazor.Generator/src/PlotlyJsInterop.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ namespace Plotly.Blazor;
/// </summary>
public class PlotlyJsInterop
{
private const string InteropPath = "/_content/Plotly.Blazor/plotly-interop.js";
private const string InteropPath = "./_content/Plotly.Blazor/plotly-interop.js";
private readonly DotNetObjectReference<PlotlyChart> dotNetObj;
private readonly Lazy<Task<IJSObjectReference>> moduleTask;

Expand Down
2 changes: 1 addition & 1 deletion Plotly.Blazor.Generator/src/wwwroot/plotly-interop.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import '/_content/Plotly.Blazor/plotly-latest.min.js';
import './plotly-latest.min.js';

export function newPlot(id, data = [], layout = {}, config = {}, frames = []) {
window.Plotly.newPlot(id, data, layout, config, frames);
Expand Down
12 changes: 12 additions & 0 deletions Plotly.Blazor/LayoutLib/Legend.cs
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,12 @@ public class Legend : IEquatable<Legend>
[JsonPropertyName(@"grouptitlefont")]
public Plotly.Blazor.LayoutLib.LegendLib.GroupTitleFont GroupTitleFont { get; set;}

/// <summary>
/// Sets the indentation (in px) of the legend entries.
/// </summary>
[JsonPropertyName(@"indentation")]
public decimal? Indentation { get; set;}

/// <summary>
/// Determines the behavior on legend item click. <c>toggle</c> toggles the
/// visibility of the item clicked on the graph. <c>toggleothers</c> makes the
Expand Down Expand Up @@ -270,6 +276,11 @@ public bool Equals([AllowNull] Legend other)
GroupTitleFont != null &&
GroupTitleFont.Equals(other.GroupTitleFont)
) &&
(
Indentation == other.Indentation ||
Indentation != null &&
Indentation.Equals(other.Indentation)
) &&
(
ItemClick == other.ItemClick ||
ItemClick != null &&
Expand Down Expand Up @@ -371,6 +382,7 @@ public override int GetHashCode()
if (Font != null) hashCode = hashCode * 59 + Font.GetHashCode();
if (GroupClick != null) hashCode = hashCode * 59 + GroupClick.GetHashCode();
if (GroupTitleFont != null) hashCode = hashCode * 59 + GroupTitleFont.GetHashCode();
if (Indentation != null) hashCode = hashCode * 59 + Indentation.GetHashCode();
if (ItemClick != null) hashCode = hashCode * 59 + ItemClick.GetHashCode();
if (ItemDoubleClick != null) hashCode = hashCode * 59 + ItemDoubleClick.GetHashCode();
if (ItemSizing != null) hashCode = hashCode * 59 + ItemSizing.GetHashCode();
Expand Down
89 changes: 88 additions & 1 deletion Plotly.Blazor/Plotly.Blazor.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4567,6 +4567,11 @@
with its size increased about 10%.
</summary>
</member>
<member name="P:Plotly.Blazor.LayoutLib.Legend.Indentation">
<summary>
Sets the indentation (in px) of the legend entries.
</summary>
</member>
<member name="P:Plotly.Blazor.LayoutLib.Legend.ItemClick">
<summary>
Determines the behavior on legend item click. <c>toggle</c> toggles the
Expand Down Expand Up @@ -74517,7 +74522,14 @@
<member name="P:Plotly.Blazor.Traces.Scatter.FillColor">
<summary>
Sets the fill color. Defaults to a half-transparent variant of the line
color, marker color, or marker line color, whichever is available.
color, marker color, or marker line color, whichever is available. If fillgradient
is specified, fillcolor is ignored except for setting the background color
of the hover label, if any.
</summary>
</member>
<member name="P:Plotly.Blazor.Traces.Scatter.FillGradient">
<summary>
Sets a fill gradient. If not specified, the fillcolor is used instead.
</summary>
</member>
<member name="P:Plotly.Blazor.Traces.Scatter.FillPattern">
Expand Down Expand Up @@ -87036,6 +87048,81 @@
order.
</summary>
</member>
<member name="T:Plotly.Blazor.Traces.ScatterLib.FillGradient">
<summary>
The FillGradient class.
</summary>
</member>
<member name="P:Plotly.Blazor.Traces.ScatterLib.FillGradient.ColorScale">
<summary>
Sets the fill gradient colors as a color scale. The color scale is interpreted
as a gradient applied in the direction specified by <c>orientation</c>,
from the lowest to the highest value of the scatter plot along that axis,
or from the center to the most distant point from it, if orientation is
<c>radial</c>.
</summary>
</member>
<member name="P:Plotly.Blazor.Traces.ScatterLib.FillGradient.Start">
<summary>
Sets the gradient start value. It is given as the absolute position on the
axis determined by the orientiation. E.g., if orientation is <c>horizontal</c>,
the gradient will be horizontal and start from the x-position given by start.
If omitted, the gradient starts at the lowest value of the trace along the
respective axis. Ignored if orientation is <c>radial</c>.
</summary>
</member>
<member name="P:Plotly.Blazor.Traces.ScatterLib.FillGradient.Stop">
<summary>
Sets the gradient end value. It is given as the absolute position on the
axis determined by the orientiation. E.g., if orientation is <c>horizontal</c>,
the gradient will be horizontal and end at the x-position given by end.
If omitted, the gradient ends at the highest value of the trace along the
respective axis. Ignored if orientation is <c>radial</c>.
</summary>
</member>
<member name="P:Plotly.Blazor.Traces.ScatterLib.FillGradient.Type">
<summary>
Sets the type/orientation of the color gradient for the fill. Defaults to
<c>none</c>.
</summary>
</member>
<member name="M:Plotly.Blazor.Traces.ScatterLib.FillGradient.Equals(System.Object)">
<inheritdoc />
</member>
<member name="M:Plotly.Blazor.Traces.ScatterLib.FillGradient.Equals(Plotly.Blazor.Traces.ScatterLib.FillGradient)">
<inheritdoc />
</member>
<member name="M:Plotly.Blazor.Traces.ScatterLib.FillGradient.GetHashCode">
<inheritdoc />
</member>
<member name="M:Plotly.Blazor.Traces.ScatterLib.FillGradient.op_Equality(Plotly.Blazor.Traces.ScatterLib.FillGradient,Plotly.Blazor.Traces.ScatterLib.FillGradient)">
<summary>
Checks for equality of the left FillGradient and the right FillGradient.
</summary>
<param name="left">Left FillGradient.</param>
<param name="right">Right FillGradient.</param>
<returns>Boolean</returns>
</member>
<member name="M:Plotly.Blazor.Traces.ScatterLib.FillGradient.op_Inequality(Plotly.Blazor.Traces.ScatterLib.FillGradient,Plotly.Blazor.Traces.ScatterLib.FillGradient)">
<summary>
Checks for inequality of the left FillGradient and the right FillGradient.
</summary>
<param name="left">Left FillGradient.</param>
<param name="right">Right FillGradient.</param>
<returns>Boolean</returns>
</member>
<member name="M:Plotly.Blazor.Traces.ScatterLib.FillGradient.DeepClone">
<summary>
Gets a deep copy of this instance.
</summary>
<returns>FillGradient</returns>
</member>
<member name="T:Plotly.Blazor.Traces.ScatterLib.FillGradientLib.TypeEnum">
<summary>
Sets the type/orientation of the color gradient for the fill. Defaults to
<c>none</c>.
</summary>
</member>
<member name="T:Plotly.Blazor.Traces.ScatterLib.FillPattern">
<summary>
The FillPattern class.
Expand Down
4 changes: 0 additions & 4 deletions Plotly.Blazor/PlotlyJsInterop.cs
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,6 @@ public PlotlyJsInterop(IJSRuntime jsRuntime, PlotlyChart chart)
() => jsRuntime.InvokeAsync<IJSObjectReference>("import", InteropPath).AsTask());
}

//// Use custom jsInterop functions to prevent exceptions caused by circle references in the return value
//// Should be fixed in future blazor wasm releases
//private const string PlotlyInterop = "plotlyInterop";

internal static readonly JsonSerializerOptions SerializerOptions = new()
{
PropertyNamingPolicy = null,
Expand Down
16 changes: 15 additions & 1 deletion Plotly.Blazor/Traces/Scatter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -110,11 +110,19 @@ public class Scatter : ITrace, IEquatable<Scatter>

/// <summary>
/// Sets the fill color. Defaults to a half-transparent variant of the line
/// color, marker color, or marker line color, whichever is available.
/// color, marker color, or marker line color, whichever is available. If fillgradient
/// is specified, fillcolor is ignored except for setting the background color
/// of the hover label, if any.
/// </summary>
[JsonPropertyName(@"fillcolor")]
public object FillColor { get; set;}

/// <summary>
/// Sets a fill gradient. If not specified, the fillcolor is used instead.
/// </summary>
[JsonPropertyName(@"fillgradient")]
public Plotly.Blazor.Traces.ScatterLib.FillGradient FillGradient { get; set;}

/// <summary>
/// Sets the pattern within the marker.
/// </summary>
Expand Down Expand Up @@ -802,6 +810,11 @@ public bool Equals([AllowNull] Scatter other)
FillColor != null &&
FillColor.Equals(other.FillColor)
) &&
(
FillGradient == other.FillGradient ||
FillGradient != null &&
FillGradient.Equals(other.FillGradient)
) &&
(
FillPattern == other.FillPattern ||
FillPattern != null &&
Expand Down Expand Up @@ -1167,6 +1180,7 @@ public override int GetHashCode()
if (ErrorY != null) hashCode = hashCode * 59 + ErrorY.GetHashCode();
if (Fill != null) hashCode = hashCode * 59 + Fill.GetHashCode();
if (FillColor != null) hashCode = hashCode * 59 + FillColor.GetHashCode();
if (FillGradient != null) hashCode = hashCode * 59 + FillGradient.GetHashCode();
if (FillPattern != null) hashCode = hashCode * 59 + FillPattern.GetHashCode();
if (GroupNorm != null) hashCode = hashCode * 59 + GroupNorm.GetHashCode();
if (HoverInfo != null) hashCode = hashCode * 59 + HoverInfo.GetHashCode();
Expand Down
Loading

0 comments on commit cf6320f

Please sign in to comment.