CollabVMDesktopClient/CollabVMClient/Views/CollabVMChatView.axaml

33 lines
1.5 KiB
Text
Raw Normal View History

2023-08-29 08:52:35 -04:00
<Window xmlns="https://github.com/avaloniaui"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:av="clr-namespace:TheArtOfDev.HtmlRenderer.Avalonia;assembly=Avalonia.HtmlRenderer"
xmlns:i="https://github.com/projektanker/icons.avalonia"
xmlns:vlc="clr-namespace:LibVLCSharp.Avalonia;assembly=LibVLCSharp.Avalonia"
mc:Ignorable="d" d:DesignWidth="400" d:DesignHeight="800"
x:Class="CollabVMClient.Views.CollabVMChatView"
Title="{Binding Title}"
Width="400" Height="800" CanResize="False">
<StackPanel Orientation="Vertical">
<ScrollViewer Width="400" Height="765">
<ItemsControl ItemsSource="{Binding ChatMessages}">
<ItemsControl.ItemTemplate>
<DataTemplate>
<av:HtmlPanel Text="{Binding HTML}" Width="400" MaxWidth="400"/>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
</ScrollViewer>
<StackPanel Orientation="Horizontal">
<TextBlock Margin="5 0 0 0" VerticalAlignment="Center" FontWeight="Bold" Text="{Binding Username}" Width="95"/>
<TextBox Name="chatInput" AcceptsReturn="False" Width="250"/>
<Button Name="sendBtn" Background="Blue" Width="50" Height="35">
<i:Icon Value="mdi-send" FontSize="25" Foreground="LightGray"/>
</Button>
</StackPanel>
<vlc:VideoView MediaPlayer="{Binding Player}" IsVisible="False"/>
</StackPanel>
</Window>