-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #85 from Brixel/joren/feat/homepage
Joren/feat/homepage
- Loading branch information
Showing
10 changed files
with
122 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1 @@ | ||
@inject NavigationManager Navigation | ||
|
||
@code { | ||
protected override void OnInitialized() | ||
{ | ||
Navigation.NavigateTo("Account/Login", true); | ||
} | ||
} | ||
<RedirectTo Uri="Account/Login"></RedirectTo> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
@page "/about" | ||
@using System.Reflection | ||
|
||
<h3 class="my-6">About</h3> | ||
|
||
<MudText Typo="Typo.body1">Version: @_version</MudText> | ||
|
||
@code { | ||
|
||
private string _version | ||
{ | ||
get | ||
{ | ||
var assembly = Assembly.GetExecutingAssembly(); | ||
var gitVersionInformationType = assembly.GetType("GitVersionInformation"); | ||
var fullSemVerField = gitVersionInformationType?.GetField("FullSemVer"); | ||
return fullSemVerField?.GetValue(null)?.ToString() ?? "0.0.0"; | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
@page "/home" | ||
@inject NavigationManager Navigation | ||
|
||
<h1 class="my-6">Welcome to HaSpMan</h1> | ||
|
||
<div class="button-row"> | ||
<CardButton Icon="@Icons.Filled.PersonAdd" OnClick="@(() => Navigate("/members/new"))"> | ||
Add Member | ||
</CardButton> | ||
|
||
<CardButton Icon="@Icons.Filled.People" OnClick="@(() => Navigate("/members"))"> | ||
List Members | ||
</CardButton> | ||
|
||
<CardButton Icon="@Icons.Filled.CompareArrows" OnClick="@(() => Navigate("/transactions/new"))"> | ||
Add Transaction | ||
</CardButton> | ||
|
||
<CardButton Icon="@Icons.Filled.List" OnClick="@(() => Navigate("/transactions"))"> | ||
List Transactions | ||
</CardButton> | ||
</div> | ||
|
||
@code { | ||
void Navigate(string uri) | ||
{ | ||
Navigation.NavigateTo(uri, true); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
.button-row { | ||
display: flex; | ||
flex-direction: row; | ||
justify-content: flex-start; | ||
align-items: center; | ||
flex-wrap: wrap; | ||
gap: 3rem; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
@page "/" | ||
<RedirectTo Uri="home"></RedirectTo> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
<MudCard Class="card"> | ||
<MudCardContent Class="pa-0"> | ||
<div class="pa-9 button" @onclick="OnClick"> | ||
<MudIcon Icon="@Icon"></MudIcon> | ||
<MudText Class="mt-3" Typo="Typo.h6">@ChildContent</MudText> | ||
</div> | ||
</MudCardContent> | ||
</MudCard> | ||
|
||
@code { | ||
|
||
[Parameter] | ||
public string Icon { get; set; } = string.Empty; | ||
|
||
[Parameter] | ||
public RenderFragment? ChildContent { get; set; } | ||
|
||
[Parameter] | ||
public EventCallback OnClick { get; set; } | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
.button { | ||
min-width: 10rem; | ||
display: flex; | ||
flex-direction: column; | ||
justify-content: flex-start; | ||
align-items: center; | ||
cursor: pointer; | ||
} | ||
|
||
.button:hover { | ||
filter: blur(50); | ||
background-color: #DDDDDD; | ||
} | ||
|
||
::deep .mud-paper.mud-card { | ||
background-color: red; | ||
} | ||
|
||
::deep .mud-icon-root.mud-svg-icon { | ||
font-size: 5rem; | ||
} | ||
|
||
::deep .mud-icon-root.mud-svg-icon path { | ||
color: #4a4657; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
.title { | ||
color: white; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
@inject NavigationManager Navigation | ||
|
||
@code { | ||
[Parameter] | ||
public string Uri { get; set; } = string.Empty; | ||
|
||
protected override void OnInitialized() | ||
{ | ||
Navigation.NavigateTo(Uri, true); | ||
} | ||
} |