55 lines
1.3 KiB
C#
55 lines
1.3 KiB
C#
using RobotNet.WebApp.Charts.Enums;
|
|
using System.Text.Json.Serialization;
|
|
|
|
namespace RobotNet.WebApp.Charts.Models.Common.Elements;
|
|
|
|
public class Point
|
|
{
|
|
/// <summary>
|
|
/// Point radius.
|
|
/// </summary>
|
|
public double Radius { get; set; } = 3;
|
|
|
|
/// <summary>
|
|
/// Point style.
|
|
/// </summary>
|
|
public PointStyle PointStyle { get; set; } = PointStyle.Circle;
|
|
|
|
/// <summary>
|
|
/// Point rotation (in degrees).
|
|
/// </summary>
|
|
public double Rotation { get; set; }
|
|
|
|
/// <summary>
|
|
/// Point fill color.
|
|
/// </summary>
|
|
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
|
|
public string? BackgroundColor { get; set; }
|
|
|
|
/// <summary>
|
|
/// Point stroke width.
|
|
/// </summary>
|
|
public int BorderWidth { get; set; } = 1;
|
|
|
|
/// <summary>
|
|
/// Point stroke color.
|
|
/// </summary>
|
|
[JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)]
|
|
public string? BorderColor { get; set; }
|
|
|
|
/// <summary>
|
|
/// Extra radius added to point radius for hit detection.
|
|
/// </summary>
|
|
public double HitRadius { get; set; } = 1;
|
|
|
|
/// <summary>
|
|
/// Point radius when hovered.
|
|
/// </summary>
|
|
public int HhoverRadius { get; set; } = 4;
|
|
|
|
/// <summary>
|
|
/// Stroke width when hovered.
|
|
/// </summary>
|
|
public int HoverBorderWidth { get; set; } = 1;
|
|
}
|