Skip to content

Commit

Permalink
Update QuestionPost.razor
Browse files Browse the repository at this point in the history
  • Loading branch information
mythz committed Mar 25, 2024
1 parent aa44bb3 commit 22a0bd0
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion MyApp/Components/Shared/QuestionPost.razor
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<h1 class="text-4xl font-bold tracking-tight text-gray-900 dark:text-gray-100 sm:text-5xl">
<span class="block xl:inline">@Question.Post.Title</span>
</h1>
<div class="my-4 py-2 flex border-b border-gray-200 dark:border-gray-700">
<div class="my-4 py-2 flex justify-between border-b border-gray-200 dark:border-gray-700">
<div class="flex gap-x-6 text-sm text-gray-500 dark:text-gray-400">
<div>
<a class="text-indigo-700 dark:text-indigo-200 hover:underline" target="_blank" href=@StackOverflowUrl>asked</a>
Expand All @@ -28,6 +28,15 @@
<b>@($"{Question.ViewCount:n0}") times</b>
</div>
</div>
@if (Question.Post.CreatedBy != null)
{
<div class="flex mr-4">
<img id="user-avatar" class="h-8 w-8 rounded-full" src="/avatar/@Question.Post.CreatedBy" alt=@($"{Question.Post.CreatedBy} avatar")>
<div>
<b class="ml-2">@Question.Post.CreatedBy</b>
</div>
</div>
}
</div>
<div class="flex">

Expand Down

0 comments on commit 22a0bd0

Please sign in to comment.