feat: Elements panel, Countdown/Web sources, webcam border config (TASK 14 Branch 2)

- New SourceType.Countdown (Starting/BRB only, timer 1-60 min) and SourceType.WebSource (all scenes, URI)
- Elements panel beneath Sources: per-element config with live preview, ✕ revert / ✓ applied indicator
- Webcam border: hex color input + swatch picker, thickness 0-10 slider
- Countdown: timer minutes slider (1-60, default 15), Web: URI text input
- SourceTypeToVisibilityConverter for conditional panel visibility
- Snapshot/revert mechanism in code-behind for live-preview cancel
This commit is contained in:
2026-08-17 07:53:03 -07:00
parent a3dd0791db
commit 16f905c8d7
7 changed files with 230 additions and 6 deletions
@@ -0,0 +1,21 @@
using System.Globalization;
using System.Windows;
using System.Windows.Data;
using ytLive.Models;
namespace ytLive.Helpers;
public class SourceTypeToVisibilityConverter : IValueConverter
{
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
if (value is not SourceType current || parameter is not string targetName)
return Visibility.Collapsed;
return Enum.TryParse<SourceType>(targetName, true, out var target) && current == target
? Visibility.Visible
: Visibility.Collapsed;
}
public object ConvertBack(object value, Type targetType, object parameter, CultureInfo culture)
=> throw new NotSupportedException();
}