Social bar (Branch B): global resource with per-scene presence — Models/Socials.cs (19 services, icons, canonical URLs), Services/SocialValidator.cs (HTTP lookup validation seam), LayoutStore schema v7 (Socials + SocialEntry tables + Scene.HasSocialBar), MainViewModel (socials collection, AddSocial/RemoveSocial/ToggleSceneSocialBar commands, freemium cap YT+1, premium seam), MainWindow.xaml (footer Social button + [+/-] toggle on meter line, preview bar rendering top/bottom + LCR), 4 integration tests (roundtrip, empty-not-persisted, canonical URLs, icons), 85 tests passing, 0 warnings
This commit is contained in:
@@ -651,6 +651,40 @@
|
||||
FontSize="180" TextAlignment="Center"/>
|
||||
</Viewbox>
|
||||
</Grid>
|
||||
|
||||
<!-- Social bar: horizontal chip row at the top or bottom of the
|
||||
frame, justified LCR. Global resource, shown per-scene. -->
|
||||
<Grid Width="1920" Canvas.Top="{Binding SocialBarTop}" IsHitTestVisible="False"
|
||||
Visibility="{Binding SceneHasSocialBar, Converter={StaticResource BoolToVis}}">
|
||||
<ItemsControl ItemsSource="{Binding Socials.Entries}"
|
||||
HorizontalAlignment="{Binding SocialBarAlign}"
|
||||
Margin="40,8">
|
||||
<ItemsControl.ItemsPanel>
|
||||
<ItemsPanelTemplate>
|
||||
<StackPanel Orientation="Horizontal"/>
|
||||
</ItemsPanelTemplate>
|
||||
</ItemsControl.ItemsPanel>
|
||||
<ItemsControl.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<StackPanel Orientation="Horizontal" Margin="0,0,20,0">
|
||||
<Border Width="28" Height="28" CornerRadius="14"
|
||||
Background="{Binding AccentColor}"
|
||||
VerticalAlignment="Center">
|
||||
<TextBlock Text="{Binding Initials}" Foreground="White"
|
||||
FontSize="11" FontWeight="Bold"
|
||||
HorizontalAlignment="Center"
|
||||
VerticalAlignment="Center"/>
|
||||
</Border>
|
||||
<TextBlock Text="{Binding Handle}" Foreground="White"
|
||||
FontSize="14" VerticalAlignment="Center"
|
||||
Margin="8,0,0,0"
|
||||
TextTrimming="CharacterEllipsis"
|
||||
MaxWidth="200"/>
|
||||
</StackPanel>
|
||||
</DataTemplate>
|
||||
</ItemsControl.ItemTemplate>
|
||||
</ItemsControl>
|
||||
</Grid>
|
||||
</Canvas>
|
||||
</Grid>
|
||||
</Viewbox>
|
||||
@@ -820,6 +854,33 @@
|
||||
PreviewMouseLeftButtonDown="VolumeSlider_PreviewMouseLeftButtonDown"
|
||||
PreviewMouseLeftButtonUp="VolumeSlider_PreviewMouseLeftButtonUp"
|
||||
LostMouseCapture="VolumeSlider_LostMouseCapture"/>
|
||||
|
||||
<Separator Margin="16,0,0,0" Background="#2a3a5e" Width="1" Height="20"
|
||||
VerticalAlignment="Center"/>
|
||||
<Button Content="Social" Command="{Binding OpenSocialDialogCommand}"
|
||||
Style="{StaticResource YtButtonSecondary}" Padding="12,4" Margin="8,0,0,0"
|
||||
FontSize="11" VerticalAlignment="Center"
|
||||
ToolTip="Add or manage your social handles"/>
|
||||
<Button Command="{Binding ToggleSceneSocialBarCommand}"
|
||||
Visibility="{Binding CanToggleSceneSocialBar, Converter={StaticResource BoolToVis}}"
|
||||
Style="{StaticResource IconButton}" Width="28" Height="28" Margin="4,0,0,0"
|
||||
VerticalAlignment="Center" FontSize="16" FontWeight="Bold"
|
||||
ToolTip="Add or remove the social bar on this scene">
|
||||
<Button.Content>
|
||||
<TextBlock FontSize="16" FontWeight="Bold">
|
||||
<TextBlock.Style>
|
||||
<Style TargetType="TextBlock">
|
||||
<Setter Property="Text" Value="+"/>
|
||||
<Style.Triggers>
|
||||
<DataTrigger Binding="{Binding SceneHasSocialBar}" Value="True">
|
||||
<Setter Property="Text" Value="−"/>
|
||||
</DataTrigger>
|
||||
</Style.Triggers>
|
||||
</Style>
|
||||
</TextBlock.Style>
|
||||
</TextBlock>
|
||||
</Button.Content>
|
||||
</Button>
|
||||
</StackPanel>
|
||||
|
||||
<!-- Line 2: everything else — stream stats on the left, quality +
|
||||
|
||||
Reference in New Issue
Block a user