using System; using System.Collections.Generic; using KernelPanic.Data; using UnityEngine; using UnityEngine.TextCore.Text; using UnityEngine.UIElements; namespace KernelPanic.UI { /// /// Renders the main menu's neofetch-style featured unit panel. /// [Serializable] public sealed class FeaturedUnitPanel { private const string EmptyAccent = "5cff91"; private VisualElement _panel; private Label _titleLabel; private Label _asciiLabel; private VisualElement _asciiPlaceholder; private Label _unitNameLabel; private Label _languagesLabel; private Label _passiveLabel; private Label _bestWaveLabel; private Label _emptyTitleLabel; private Label _emptyHintLabel; private VisualElement _populatedState; private VisualElement _emptyState; private FontAsset _monospaceFont; private AsciiArtFitter _asciiFitter; private IReadOnlyList _units = Array.Empty(); private int _selectedIndex; public void Bind(VisualElement root, FontAsset artFont) { _monospaceFont = artFont; _panel = root.Q("FeaturedUnitPanel"); _titleLabel = root.Q