Added chat page & draft content block component

This commit is contained in:
Thorsten Sommer 2024-04-22 18:56:18 +02:00
parent 8115179bb3
commit a8c35f4d07
Signed by: tsommer
GPG Key ID: 371BBA77A02C0108
4 changed files with 58 additions and 0 deletions

View File

@ -0,0 +1,18 @@
@using MudBlazor
<MudCard Class="my-2 rounded-lg" Outlined="@true">
<MudCardHeader>
<CardHeaderAvatar>
<MudAvatar Color="Color.Primary">Y</MudAvatar>
</CardHeaderAvatar>
<CardHeaderContent>
<MudText Typo="Typo.body1">You</MudText>
</CardHeaderContent>
<CardHeaderActions>
<MudIconButton Icon="@Icons.Material.Filled.ContentCopy" Color="Color.Default" />
</CardHeaderActions>
</MudCardHeader>
<MudCardContent>
<MudText Typo="Typo.body2">bla bla bla</MudText>
</MudCardContent>
</MudCard>

View File

@ -0,0 +1,7 @@
using Microsoft.AspNetCore.Components;
namespace AIStudio.Chat;
public partial class ContentBlockComponent : ComponentBase
{
}

View File

@ -0,0 +1,26 @@
@page "/chat"
@using AIStudio.Chat
<MudText Typo="Typo.h3" Class="mb-12">Chats</MudText>
<div class="d-flex flex-column" style="height: calc(100vh - 8.3em);">
<div class="flex-auto overflow-auto">
<ContentBlockComponent/>
<ContentBlockComponent/>
<ContentBlockComponent/>
<ContentBlockComponent/>
<ContentBlockComponent/>
<ContentBlockComponent/>
<ContentBlockComponent/>
<ContentBlockComponent/>
<ContentBlockComponent/>
<ContentBlockComponent/>
<ContentBlockComponent/>
<ContentBlockComponent/>
</div>
<MudPaper Style="flex: 0 0 auto;">
<MudTextField T="string" Variant="Variant.Filled" AutoGrow="@true" Lines="3" MaxLines="12" Label="Your Prompt" Placeholder="Type your question here...">
</MudTextField>
</MudPaper>
</div>

View File

@ -0,0 +1,7 @@
using Microsoft.AspNetCore.Components;
namespace AIStudio.Components.Pages;
public partial class Chat : ComponentBase
{
}