feat(scoreboard): the properties are inert until the creator is signed in
The scoreboard is fed by the signed-in channel (chat events + channel stats), so offering its switches to a signed-out user is a dead control. The whole block now binds IsEnabled to IsConnected and shows one line — "Sign in to YouTube to use the scoreboard." — instead of looking broken. Nothing extra is needed to re-enable: IsConnected already raises on sign-in/out, so the block comes alive the moment the session lands. Guard: ScoreboardPropertiesTests asserts the IsEnabled binding, the signed-out hint and that the hint is gated by the inverse converter.
This commit is contained in:
@@ -452,7 +452,14 @@
|
||||
|
||||
<!-- Scoreboard config (creator 2026-10-30): the ego wall's billboard —
|
||||
which eight facts show, and how the strip is painted. -->
|
||||
<StackPanel Visibility="{Binding SelectedElement.IsScoreboard, Converter={StaticResource BoolToVis}}" Margin="0,0,0,8">
|
||||
<!-- The scoreboard is fed by the signed-in channel, so its controls are
|
||||
inert until there is an account; signing in re-enables them through
|
||||
the ordinary IsConnected notification. -->
|
||||
<StackPanel Visibility="{Binding SelectedElement.IsScoreboard, Converter={StaticResource BoolToVis}}"
|
||||
IsEnabled="{Binding IsConnected}" Margin="0,0,0,8">
|
||||
<TextBlock Text="Sign in to YouTube to use the scoreboard."
|
||||
Foreground="{StaticResource Brush.OnSurfaceVariant}" FontSize="11" Margin="0,0,0,4"
|
||||
Visibility="{Binding IsConnected, Converter={StaticResource InverseBoolToVis}}"/>
|
||||
<CheckBox Style="{StaticResource YtCheckBox}" Margin="0,0,0,4"
|
||||
Content="Show the scoreboard" IsChecked="{Binding ScoreboardEnabled, Mode=TwoWay}"
|
||||
ToolTip="Off hides the strip in every scene AND stops the channel polling."/>
|
||||
|
||||
Reference in New Issue
Block a user