<?xml version="1.0" encoding="utf-8" ?>
<local:MomentUperSectionControlBase
    x:Class="BiliCopilot.UI.Controls.Moment.MomentUperItemControl"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:base="using:Richasy.WinUIKernel.Share.Base"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:ic="using:FluentIcons.WinUI"
    xmlns:local="using:BiliCopilot.UI.Controls.Moment"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    mc:Ignorable="d">

    <Grid Padding="12,0" ColumnSpacing="12">
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="Auto" />
            <ColumnDefinition />
            <ColumnDefinition Width="Auto" />
        </Grid.ColumnDefinitions>

        <Grid VerticalAlignment="Center">
            <ic:SymbolIcon
                Margin="4,0,6,0"
                VerticalAlignment="Center"
                FontSize="16"
                Symbol="BubbleMultiple"
                Visibility="{x:Bind ViewModel.IsTotal, Mode=OneWay}" />
            <PersonPicture
                Width="28"
                Height="28"
                VerticalAlignment="Center"
                DisplayName="{x:Bind ViewModel.Name, Mode=OneWay}"
                ProfilePicture="{x:Bind ViewModel.Avatar, Mode=OneWay, Converter={StaticResource BitmapConverter}}"
                Visibility="{x:Bind ViewModel.IsTotal, Mode=OneWay, Converter={StaticResource BoolToVisibilityReverseConverter}}" />
        </Grid>

        <base:TrimTextBlock
            Grid.Column="1"
            VerticalAlignment="Center"
            Text="{x:Bind ViewModel.Name, Mode=OneWay}" />

        <Ellipse
            Grid.Column="2"
            Width="8"
            Height="8"
            VerticalAlignment="Center"
            Fill="{ThemeResource AccentFillColorDefaultBrush}"
            Visibility="{x:Bind ViewModel.HasUnread, Mode=OneWay}" />
    </Grid>
</local:MomentUperSectionControlBase>
