From f1a6985061a6f4e587c25ea7e87b25487c1b281c Mon Sep 17 00:00:00 2001 From: Eric Wassail <eric@hypar.io> Date: Thu, 7 Dec 2023 14:08:54 -0500 Subject: [PATCH] additional props on contentConfigurations --- Elements.Components/src/SpaceConfiguration.cs | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/Elements.Components/src/SpaceConfiguration.cs b/Elements.Components/src/SpaceConfiguration.cs index 6629d14ce..29ca8f048 100644 --- a/Elements.Components/src/SpaceConfiguration.cs +++ b/Elements.Components/src/SpaceConfiguration.cs @@ -21,6 +21,11 @@ public class SpaceConfiguration : Dictionary<string, ContentConfiguration> /// </summary> public class ContentConfiguration { + /// <summary> + /// A collection of additional properties. + /// </summary> + [Newtonsoft.Json.JsonExtensionData] + public IDictionary<string, object> AdditionalProperties { get; set; } = new Dictionary<string, object>(); /// <summary> /// A rectangular boundary around this content configuration. @@ -119,7 +124,7 @@ public ContentElement ContentElement public BoundaryDefinition CellBoundary { get; set; } /// <summary> - /// The individual content itmems in this configuration. + /// The individual content items in this configuration. /// </summary> public List<ContentItem> ContentItems { get; set; } @@ -127,12 +132,12 @@ public ContentElement ContentElement /// <summary> /// The width of the configuration boundary. /// </summary> - public double Width => this.CellBoundary.Width; + public double Width => CellBoundary.Width; /// <summary> /// The depth of the configuration boundary. /// </summary> - public double Depth => this.CellBoundary.Depth; + public double Depth => CellBoundary.Depth; /// <summary> /// Allow rotation of the configuration @@ -173,7 +178,7 @@ public static List<Vector3> AnchorsFromRect(Polygon polygon) /// </summary> public List<Vector3> Anchors() { - var baseRect = Polygon.Rectangle(this.CellBoundary.Min, this.CellBoundary.Max); + var baseRect = Polygon.Rectangle(CellBoundary.Min, CellBoundary.Max); var baseAnchors = AnchorsFromRect(baseRect); return baseAnchors; }