<?xml version="1.0" encoding="utf-8" ?>
<base:LayoutUserControlBase
    x:Class="BiliCopilot.UI.Controls.Article.ArticleReader"
    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:ext="using:BiliCopilot.UI.Extensions"
    xmlns:ic="using:FluentIcons.WinUI"
    xmlns:local="using:BiliCopilot.UI.Controls.Article"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    mc:Ignorable="d">

    <UserControl.Resources>
        <MenuFlyout x:Name="TextMenuFlyout">
            <MenuFlyoutItem
                Click="OnCopyItemClick"
                KeyboardAcceleratorTextOverride="Ctrl + C"
                Text="{ext:Locale Name=CopyToClipboard}">
                <MenuFlyoutItem.Icon>
                    <ic:SymbolIcon Symbol="Copy" />
                </MenuFlyoutItem.Icon>
            </MenuFlyoutItem>
            <MenuFlyoutItem Click="OnSearchItemClickAsync" Text="{ext:Locale Name=SearchInWeb}">
                <MenuFlyoutItem.Icon>
                    <ic:SymbolIcon Symbol="GlobeSearch" />
                </MenuFlyoutItem.Icon>
            </MenuFlyoutItem>
        </MenuFlyout>
    </UserControl.Resources>

    <Grid>
        <WebView2
            x:Name="MainView"
            HorizontalAlignment="Stretch"
            VerticalAlignment="Stretch"
            DefaultBackgroundColor="Transparent" />
    </Grid>
</base:LayoutUserControlBase>
