| 1 | <UserControl xmlns="https://github.com/avaloniaui" |
| 2 | xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
| 3 | xmlns:vm="using:CascadeIDE.ViewModels" |
| 4 | xmlns:dbg="using:CascadeIDE.Features.Debug" |
| 5 | xmlns:views="using:CascadeIDE.Views" |
| 6 | x:Class="CascadeIDE.Views.HypothesesMfdPageView" |
| 7 | x:DataType="vm:MainWindowViewModel"> |
| 8 | <!-- Страница Mfd «Гипотезы»; DataContext снаружи — MainWindowViewModel. --> |
| 9 | <DockPanel DataContext="{Binding HypothesesPanel}" x:DataType="dbg:HypothesesPanelViewModel"> |
| 10 | <views:PanelChromeHeader DockPanel.Dock="Top" Classes="terminal" Title="Гипотезы · workspace JSON" UppercaseTitle="True"/> |
| 11 | <StackPanel DockPanel.Dock="Top" Orientation="Horizontal" Spacing="8" Margin="0,0,0,6"> |
| 12 | <Button Content="Добавить гипотезу" Command="{Binding AddHypothesisCommand}" Padding="8,4"/> |
| 13 | <TextBlock Text=".cascade-ide/debug-hypotheses.json" |
| 14 | VerticalAlignment="Center" |
| 15 | FontSize="11" |
| 16 | Foreground="{DynamicResource CascadeTheme.ChatLabelForeground}"/> |
| 17 | </StackPanel> |
| 18 | <ScrollViewer VerticalScrollBarVisibility="Auto"> |
| 19 | <ItemsControl ItemsSource="{Binding Items}"> |
| 20 | <ItemsControl.ItemTemplate> |
| 21 | <DataTemplate DataType="dbg:HypothesisRowViewModel"> |
| 22 | <Border Padding="6" Margin="0,0,0,6" |
| 23 | BorderBrush="{DynamicResource CascadeTheme.EditorColumnBorderBrush}" |
| 24 | BorderThickness="1" CornerRadius="4"> |
| 25 | <StackPanel Spacing="6"> |
| 26 | <TextBox Text="{Binding Text, Mode=TwoWay}" |
| 27 | AcceptsReturn="True" |
| 28 | TextWrapping="Wrap" |
| 29 | MinHeight="48" |
| 30 | FontFamily="Consolas,monospace" |
| 31 | FontSize="12" |
| 32 | PlaceholderText="Формулировка гипотезы…"/> |
| 33 | <StackPanel Orientation="Horizontal" Spacing="6"> |
| 34 | <Button Content="Открыта" Command="{Binding SetOpenCommand}" Padding="6,2"/> |
| 35 | <Button Content="Не подтвердилась" Command="{Binding SetRejectedCommand}" Padding="6,2"/> |
| 36 | <Button Content="Подтвердилась" Command="{Binding SetConfirmedCommand}" Padding="6,2"/> |
| 37 | <Button Content="Удалить" Command="{Binding RemoveCommand}" Padding="6,2" Margin="12,0,0,0"/> |
| 38 | </StackPanel> |
| 39 | </StackPanel> |
| 40 | </Border> |
| 41 | </DataTemplate> |
| 42 | </ItemsControl.ItemTemplate> |
| 43 | </ItemsControl> |
| 44 | </ScrollViewer> |
| 45 | </DockPanel> |
| 46 | </UserControl> |
| 47 | |