Skip to content

Commit

Permalink
put message input at the bottom
Browse files Browse the repository at this point in the history
  • Loading branch information
NielsPilgaard committed Sep 3, 2023
1 parent 5f21d98 commit a23f586
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
3 changes: 1 addition & 2 deletions src/web/Client/Features/Chat/LargeChatComponent.razor
Original file line number Diff line number Diff line change
Expand Up @@ -96,13 +96,12 @@
Class="message-sent-successfully" />
</div>
}
<div class="flex-spacer"></div>

<MudTextField @bind-Value="_userText"
FullWidth
Immediate
AutoFocus
id="chat-message-input"
Class="chat-message-input"
Adornment="Adornment.End"
TextUpdateSuppression="false"
OnKeyDown="SendMessageOnEnter"
Expand Down
11 changes: 11 additions & 0 deletions src/web/Client/wwwroot/css/chat.css
Original file line number Diff line number Diff line change
Expand Up @@ -40,3 +40,14 @@
.message-sent-successfully {
font-size: 14px;
}
.flex-spacer {
flex-grow: 1;
}
.chat-message-list .mud-input-control {
flex: none; /* or flex: none; depending on what you want */
}
.chat-message-list {
display: flex;
flex-direction: column;
min-height: 100%;
}

0 comments on commit a23f586

Please sign in to comment.