+
+
+ Development Mode
- Swapping to Development environment will display more detailed information about the error that occurred. + Swapping to Development environment will display more detailed information about the error that + occurred.
The Development environment shouldn't be enabled for deployed applications. It can result in displaying sensitive information from exceptions to end users. - For local debugging, enable the Development environment by setting the ASPNETCORE_ENVIRONMENT environment variable to Development + For local debugging, enable the Development environment by setting the ASPNETCORE_ENVIRONMENT + environment variable to Development and restarting the app.
@code{ + [CascadingParameter] private HttpContext? HttpContext { get; set; } private string? RequestId { get; set; } private bool ShowRequestId => !string.IsNullOrEmpty(RequestId); - protected override void OnInitialized() => + protected override void OnInitialized() + { RequestId = Activity.Current?.Id ?? HttpContext?.TraceIdentifier; + } + } diff --git a/src/BlazorApp/Components/Pages/Experience.razor b/src/BlazorApp/Components/Pages/Experience.razor new file mode 100644 index 0000000..0b0d6aa --- /dev/null +++ b/src/BlazorApp/Components/Pages/Experience.razor @@ -0,0 +1,107 @@ +@page "/experience" + ++ Software Engineer since 2018 +
+ +-
+ @foreach (var item in experienceTimelineItems)
+ {
+
-
+
+
+ @item.Title @("@")
+ @foreach (var content in item.Content) + { +@item.CompanyName +@content + } +
+ }
+
Hello, world!
- -Welcome to your new app. +Not Found
-Sorry, the content you are looking for does not exist.
\ No newline at end of file +404
++ Page not found +
+Sorry, this page doesn't exist.
+Weather
- -This component demonstrates showing data.
- -@if (forecasts == null) -{ -Loading...
-} -else -{ -| Date | -Temp. (C) | -Temp. (F) | -Summary | -
|---|---|---|---|
| @forecast.Date.ToShortDateString() | -@forecast.TemperatureC | -@forecast.TemperatureF | -@forecast.Summary | -
@ChildContent
+ +@code { + + [Parameter] + public RenderFragment? ChildContent { get; set; } + + [Parameter] + public string? CssClass { get; set; } + + private string CombinedClasses => string.IsNullOrEmpty(CssClass) + ? "flex items-center text-2xl py-4 font-semibold" + : $"flex items-center text-2xl py-4 font-semibold {CssClass}"; + +} diff --git a/src/BlazorApp/Components/Typography/Text/Text.razor b/src/BlazorApp/Components/Typography/Text/Text.razor new file mode 100644 index 0000000..1c84a7c --- /dev/null +++ b/src/BlazorApp/Components/Typography/Text/Text.razor @@ -0,0 +1,17 @@ +@* Paragraph component *@ + +@ChildContent
+ +@code { + + [Parameter] + public RenderFragment? ChildContent { get; set; } + + [Parameter] + public string? CssClass { get; set; } + + private string CombinedClasses => string.IsNullOrEmpty(CssClass) + ? "text-paragraph" + : $"text-paragraph {CssClass}"; + +} diff --git a/src/BlazorApp/Components/Typography/Title/Title.razor b/src/BlazorApp/Components/Typography/Title/Title.razor new file mode 100644 index 0000000..8bd2702 --- /dev/null +++ b/src/BlazorApp/Components/Typography/Title/Title.razor @@ -0,0 +1,17 @@ +@* H1 heading component *@ + +