diff --git a/src/Connected.Components.Showcase.Runner/Connected.Components.Showcase.Runner.csproj b/src/Connected.Components.Showcase.Runner/Connected.Components.Showcase.Runner.csproj
index 015518e..f6e0064 100644
--- a/src/Connected.Components.Showcase.Runner/Connected.Components.Showcase.Runner.csproj
+++ b/src/Connected.Components.Showcase.Runner/Connected.Components.Showcase.Runner.csproj
@@ -22,4 +22,9 @@
Izbran datum je: @date
diff --git a/src/Connected.Components/Components/FormWizardStep.razor.cs b/src/Connected.Components/Components/FormWizardStep.razor.cs index 2c64912..fbaa5b9 100644 --- a/src/Connected.Components/Components/FormWizardStep.razor.cs +++ b/src/Connected.Components/Components/FormWizardStep.razor.cs @@ -46,7 +46,7 @@ public partial class FormWizardStep get { return new CssBuilder("dot") - .AddClass("completed",Completed) + .AddClass("completed", Completed) .AddClass("next", Active) .Build(); } @@ -62,7 +62,7 @@ public partial class FormWizardStep get { return new StyleBuilder() - .AddStyle("display","none", (!Active && !IsNext && !IsPrevious)) //Workarround for more than 2 steps where steps didnt hide after + .AddStyle("display", "none", (!Active && !IsNext && !IsPrevious)) //Workarround for more than 2 steps where steps didnt hide after .AddStyle(Style) .Build(); } diff --git a/src/Connected.Components/Components/GridRowContent.razor.cs b/src/Connected.Components/Components/GridRowContent.razor.cs index 7f07735..4c76533 100644 --- a/src/Connected.Components/Components/GridRowContent.razor.cs +++ b/src/Connected.Components/Components/GridRowContent.razor.cs @@ -26,15 +26,22 @@ public partial class GridRowContent : ComponentBase { get { - return new CssBuilder("row") - .AddClass("collapsed", Collapsable) - .AddClass("show", (Collapsable ? Parent?.CollapsedItemShown : false)) - .Build(); + CssBuilder cssBuilder = new CssBuilder("row"); + + cssBuilder.AddClass("collapsed", Collapsable); + + if (Parent is not null) + { + cssBuilder.AddClass("show", (Collapsable ? Parent.CollapsedItemShown : false)); + } + + return cssBuilder.Build(); } } protected override async Task OnInitializedAsync() { + if (Parent is not null) { if (Parent.Children is null) Parent.Children = new(); diff --git a/src/Connected.Components/Enums/Color.cs b/src/Connected.Components/Enums/Color.cs index eadc7e8..96cce10 100644 --- a/src/Connected.Components/Enums/Color.cs +++ b/src/Connected.Components/Enums/Color.cs @@ -5,7 +5,7 @@ namespace Connected; public enum Color { [Description("core")] - Core, + Core, [Description("primary")] Primary, diff --git a/src/Connected.Components/Enums/ThemeProvider.cs b/src/Connected.Components/Enums/ThemeProvider.cs new file mode 100644 index 0000000..00b01ff --- /dev/null +++ b/src/Connected.Components/Enums/ThemeProvider.cs @@ -0,0 +1,23 @@ +using System.ComponentModel; + +namespace Connected; + +public enum Theme +{ + [Description("")] + Default, + + [Description("dark")] + Dark, + + [Description("light")] + Light, + + [Description("pink")] + Pink +} + +public static class ThemeProvider +{ + public static Theme theme { get; set; } = Theme.Default; +} \ No newline at end of file