feat(ui): Listeneinstellungen mit Kategorie-Sidebar
Body wie im Settings-Modal: Sidebar-Liste steuert einen retemplateten TabControl (Allgemein/Agent/Verifikation) statt einer langen Scroll-Spalte.
This commit is contained in:
@@ -6,9 +6,9 @@
|
|||||||
x:Class="ClaudeDo.Ui.Views.Modals.ListSettingsModalView"
|
x:Class="ClaudeDo.Ui.Views.Modals.ListSettingsModalView"
|
||||||
x:DataType="vm:ListSettingsModalViewModel"
|
x:DataType="vm:ListSettingsModalViewModel"
|
||||||
Title="{loc:Tr modals.listSettings.title}"
|
Title="{loc:Tr modals.listSettings.title}"
|
||||||
Width="520" Height="720"
|
Width="640" Height="720"
|
||||||
CanResize="True"
|
CanResize="True"
|
||||||
MinWidth="460" MinHeight="520"
|
MinWidth="560" MinHeight="520"
|
||||||
WindowDecorations="BorderOnly"
|
WindowDecorations="BorderOnly"
|
||||||
ExtendClientAreaToDecorationsHint="True"
|
ExtendClientAreaToDecorationsHint="True"
|
||||||
ExtendClientAreaTitleBarHeightHint="-1"
|
ExtendClientAreaTitleBarHeightHint="-1"
|
||||||
@@ -32,15 +32,42 @@
|
|||||||
</Grid>
|
</Grid>
|
||||||
</ctl:ModalShell.Footer>
|
</ctl:ModalShell.Footer>
|
||||||
|
|
||||||
<!-- Body -->
|
<!-- Body: category sidebar + tab-content host, mirroring the Settings modal. -->
|
||||||
<ScrollViewer Padding="20,16">
|
<Grid ColumnDefinitions="150,1,*">
|
||||||
<StackPanel Spacing="12">
|
|
||||||
|
<ListBox Grid.Column="0" Name="Nav" SelectedIndex="0"
|
||||||
|
Background="Transparent" Margin="12,16,8,8"
|
||||||
|
VerticalAlignment="Top">
|
||||||
|
<ListBoxItem Content="{loc:Tr modals.listSettings.sectionGeneral}"/>
|
||||||
|
<ListBoxItem Content="{loc:Tr modals.listSettings.sectionAgent}"/>
|
||||||
|
<ListBoxItem Content="{loc:Tr modals.listSettings.sectionVerify}"/>
|
||||||
|
</ListBox>
|
||||||
|
|
||||||
|
<Border Grid.Column="1" Background="{DynamicResource LineBrush}" Width="1" Margin="0,8"/>
|
||||||
|
|
||||||
|
<!-- The TabControl is the content host (index driven by the sidebar); its header strip is
|
||||||
|
re-templated away. PART_ItemsPresenter must stay (collapsed): SelectedContent is
|
||||||
|
resolved via ContainerFromIndex, and without a presenter no container is realized
|
||||||
|
-> SelectedContent is null and the body renders empty. -->
|
||||||
|
<TabControl Grid.Column="2" Padding="20,16" SelectedIndex="{Binding #Nav.SelectedIndex, Mode=OneWay}">
|
||||||
|
<TabControl.Template>
|
||||||
|
<ControlTemplate TargetType="TabControl">
|
||||||
|
<Panel>
|
||||||
|
<ItemsPresenter Name="PART_ItemsPresenter"
|
||||||
|
ItemsPanel="{TemplateBinding ItemsPanel}"
|
||||||
|
IsVisible="False"/>
|
||||||
|
<ContentPresenter Name="PART_SelectedContentHost"
|
||||||
|
Padding="{TemplateBinding Padding}"
|
||||||
|
Content="{TemplateBinding SelectedContent}"
|
||||||
|
ContentTemplate="{TemplateBinding SelectedContentTemplate}"/>
|
||||||
|
</Panel>
|
||||||
|
</ControlTemplate>
|
||||||
|
</TabControl.Template>
|
||||||
|
|
||||||
<!-- GENERAL -->
|
<!-- GENERAL -->
|
||||||
<StackPanel Spacing="0">
|
<TabItem Header="{loc:Tr modals.listSettings.sectionGeneral}">
|
||||||
<TextBlock Classes="section-label" Text="{loc:Tr modals.listSettings.sectionGeneral}"/>
|
<ScrollViewer>
|
||||||
<Border Classes="section">
|
<StackPanel Spacing="12" Margin="0,8,0,0">
|
||||||
<StackPanel Spacing="12">
|
|
||||||
<StackPanel Spacing="4">
|
<StackPanel Spacing="4">
|
||||||
<TextBlock Classes="field-label" Text="{loc:Tr modals.listSettings.name}"/>
|
<TextBlock Classes="field-label" Text="{loc:Tr modals.listSettings.name}"/>
|
||||||
<TextBox Text="{Binding Name, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" />
|
<TextBox Text="{Binding Name, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" />
|
||||||
@@ -75,13 +102,6 @@
|
|||||||
Opacity="0.6" FontSize="12" TextWrapping="Wrap"/>
|
Opacity="0.6" FontSize="12" TextWrapping="Wrap"/>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
|
|
||||||
<StackPanel Spacing="4">
|
|
||||||
<CheckBox IsChecked="{Binding SerializeOnFileOverlap, Mode=TwoWay}"
|
|
||||||
Content="{loc:Tr modals.listSettings.serializeOnFileOverlap}"/>
|
|
||||||
<TextBlock Text="{loc:Tr modals.listSettings.serializeOnFileOverlapHint}"
|
|
||||||
Opacity="0.6" FontSize="12" TextWrapping="Wrap"/>
|
|
||||||
</StackPanel>
|
|
||||||
|
|
||||||
<StackPanel Spacing="4" IsVisible="{Binding TicketsAvailable}">
|
<StackPanel Spacing="4" IsVisible="{Binding TicketsAvailable}">
|
||||||
<TextBlock Classes="field-label" Text="{loc:Tr modals.listSettings.ticketProject}"/>
|
<TextBlock Classes="field-label" Text="{loc:Tr modals.listSettings.ticketProject}"/>
|
||||||
<ComboBox ItemsSource="{Binding TicketProjects}"
|
<ComboBox ItemsSource="{Binding TicketProjects}"
|
||||||
@@ -90,37 +110,36 @@
|
|||||||
HorizontalAlignment="Left" MinWidth="240"/>
|
HorizontalAlignment="Left" MinWidth="240"/>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</Border>
|
</ScrollViewer>
|
||||||
</StackPanel>
|
</TabItem>
|
||||||
|
|
||||||
<!-- AGENT -->
|
<!-- AGENT -->
|
||||||
<StackPanel Spacing="0">
|
<TabItem Header="{loc:Tr modals.listSettings.sectionAgent}">
|
||||||
<Grid ColumnDefinitions="*,Auto" Margin="4,0,0,6">
|
<ScrollViewer>
|
||||||
<TextBlock Classes="section-label" Text="{loc:Tr modals.listSettings.sectionAgent}" Margin="0"/>
|
<StackPanel Spacing="12" Margin="0,8,0,0">
|
||||||
<Button Classes="btn" Grid.Column="1" Content="{loc:Tr modals.listSettings.resetAgentSettings}"
|
<Button Classes="btn" HorizontalAlignment="Right"
|
||||||
Command="{Binding Agent.ResetAllCommand}" />
|
Content="{loc:Tr modals.listSettings.resetAgentSettings}"
|
||||||
</Grid>
|
Command="{Binding Agent.ResetAllCommand}" />
|
||||||
<Border Classes="section">
|
<ctl:AgentConfigEditor DataContext="{Binding Agent}" ShowAgentBrowse="True"/>
|
||||||
<ctl:AgentConfigEditor DataContext="{Binding Agent}" ShowAgentBrowse="True"/>
|
</StackPanel>
|
||||||
</Border>
|
</ScrollViewer>
|
||||||
</StackPanel>
|
</TabItem>
|
||||||
|
|
||||||
<!-- VERIFICATION -->
|
<!-- VERIFICATION -->
|
||||||
<StackPanel Spacing="0">
|
<TabItem Header="{loc:Tr modals.listSettings.sectionVerify}">
|
||||||
<TextBlock Classes="section-label" Text="{loc:Tr modals.listSettings.sectionVerify}"/>
|
<ScrollViewer>
|
||||||
<Border Classes="section">
|
<StackPanel Spacing="4" Margin="0,8,0,0">
|
||||||
<StackPanel Spacing="4">
|
|
||||||
<TextBlock Classes="field-label" Text="{loc:Tr modals.listSettings.verifyCommand}"/>
|
<TextBlock Classes="field-label" Text="{loc:Tr modals.listSettings.verifyCommand}"/>
|
||||||
<TextBox Text="{Binding VerifyCommand, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
|
<TextBox Text="{Binding VerifyCommand, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
|
||||||
PlaceholderText="{loc:Tr modals.listSettings.verifyCommandPlaceholder}"/>
|
PlaceholderText="{loc:Tr modals.listSettings.verifyCommandPlaceholder}"/>
|
||||||
<TextBlock Text="{loc:Tr modals.listSettings.verifyCommandHint}"
|
<TextBlock Text="{loc:Tr modals.listSettings.verifyCommandHint}"
|
||||||
Opacity="0.6" FontSize="12" TextWrapping="Wrap"/>
|
Opacity="0.6" FontSize="12" TextWrapping="Wrap"/>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</Border>
|
</ScrollViewer>
|
||||||
</StackPanel>
|
</TabItem>
|
||||||
|
|
||||||
</StackPanel>
|
</TabControl>
|
||||||
</ScrollViewer>
|
</Grid>
|
||||||
|
|
||||||
</ctl:ModalShell>
|
</ctl:ModalShell>
|
||||||
</Window>
|
</Window>
|
||||||
|
|||||||
Reference in New Issue
Block a user