client: DeckBuilder — фиксированная правая панель и адаптивная сетка
CI / test (push) Successful in 1m55s Details

- Правая панель сокращена до 420 px и больше не растягивается
  (childForceExpandWidth = false).
- Коллекция занимает всё свободное место; число колонок считается по
  ширине, карточки не обрезаются справа.
- Проверки: EditMode 69/69, standalone собран.
This commit is contained in:
MpakobecEx 2026-11-01 15:33:14 +05:00
parent 874ec6aa1a
commit 13654ce134
1 changed files with 4 additions and 5 deletions

View File

@ -19,7 +19,7 @@ namespace Vanguard.UI
/// </summary>
public sealed class DeckBuilderView
{
private const float PanelWidth = 380f;
private const float PanelWidth = 420f;
private const float RowHeight = 92f;
private static readonly Color TextPrimary = new Color(0.88f, 0.93f, 1f);
@ -177,6 +177,9 @@ namespace Vanguard.UI
body.offsetMin = new Vector2(34f, 24f);
body.offsetMax = new Vector2(-34f, -120f);
UiKit.AddHorizontalLayout(body, 0, 14);
var bodyLayout = body.GetComponent<HorizontalLayoutGroup>();
if (bodyLayout != null)
bodyLayout.childForceExpandWidth = false;
var collectionArea = UiKit.CreatePanel(
body, "CollectionArea", new Color(0.04f, 0.06f, 0.10f, 0.55f));
@ -213,11 +216,7 @@ namespace Vanguard.UI
var grid = _collectionContent.GetComponent<GridLayoutGroup>();
if (grid != null)
{
grid.constraint = GridLayoutGroup.Constraint.FixedColumnCount;
grid.constraintCount = 6;
grid.childAlignment = TextAnchor.UpperLeft;
}
_status = UiKit.CreateText(
collectionArea, "Status", string.Empty, 15,