]> git.smokeofanarchy.ru Git - space-station-14.git/commitdiff
Character editor style fixes (#41278)
authoreoineoineoin <helloworld@eoinrul.es>
Thu, 22 Jan 2026 17:56:50 +0000 (17:56 +0000)
committerGitHub <noreply@github.com>
Thu, 22 Jan 2026 17:56:50 +0000 (17:56 +0000)
* Restore pre-StyleNano element height

* Add style for HelpButton to sheetlet

---------

Co-authored-by: Janet Blackquill <uhhadd@gmail.com>
Content.Client/Lobby/UI/CharacterSetupGui.xaml
Content.Client/Stylesheets/Sheetlets/ButtonSheetlet.cs
Content.Client/Stylesheets/StyleClass.cs
Content.Client/Stylesheets/StyleNano.cs

index 09ed989fc6ca2a5b603787a475f1f4f3facf6db7..ab264deb34124c7974dab0e810460162c01cb8ec 100644 (file)
@@ -28,8 +28,7 @@
                         Text="{Loc 'character-setup-gui-character-setup-close-button'}"
                         StyleClasses="ButtonBig"/>
             </BoxContainer>
-            <PanelContainer StyleClasses="highlight">
-            </PanelContainer>
+            <PanelContainer StyleClasses="highlight" MinHeight="2" />
             <BoxContainer Orientation="Horizontal" VerticalExpand="True" SeparationOverride="0">
                 <ScrollContainer MinSize="325 0" Margin="5 5 0 0">
                     <BoxContainer Name="Characters" Orientation="Vertical" />
index 51ba2063928f472f48dc707fcae808908a584c5d..8b92e1410aa90eb283cf9174481dceeea6bd0593 100644 (file)
@@ -19,6 +19,7 @@ public sealed class ButtonSheetlet<T> : Sheetlet<T> where T : PalettedStylesheet
 
         var crossTex = sheet.GetTextureOr(iconCfg.CrossIconPath, NanotrasenStylesheet.TextureRoot);
         var refreshTex = sheet.GetTextureOr(iconCfg.RefreshIconPath, NanotrasenStylesheet.TextureRoot);
+        var helpTex = sheet.GetTextureOr(iconCfg.HelpIconPath, NanotrasenStylesheet.TextureRoot);
 
         var rules = new List<StyleRule>
         {
@@ -56,6 +57,11 @@ public sealed class ButtonSheetlet<T> : Sheetlet<T> where T : PalettedStylesheet
                 .Class(StyleClass.RefreshButton)
                 .Prop(TextureButton.StylePropertyTexture, refreshTex),
 
+            // Help button
+            E<TextureButton>()
+                .Class(StyleClass.HelpButton)
+                .Prop(TextureButton.StylePropertyTexture, helpTex),
+
             // Ensure labels in buttons are aligned.
             E<Label>()
                 // ReSharper disable once AccessToStaticMemberViaDerivedType
index ce4e93bdc9881b19c39489f40e0e8a3a14cac5c3..6c07dba6ed7490bc685b67ec1886b626341d42bf 100644 (file)
@@ -62,6 +62,7 @@ public static class StyleClass
 
     public const string CrossButtonRed = "CrossButtonRed";
     public const string RefreshButton = "RefreshButton";
+    public const string HelpButton = "HelpButton";
 
     public const string ItemStatus = "ItemStatus";
     public const string ItemStatusNotHeld = "ItemStatusNotHeld";
index 52c340dada1c1dfae8fd41719663fcadc4b1e13f..34195d3a7c52e844f979575e710b64700d824c3f 100644 (file)
@@ -84,8 +84,6 @@ namespace Content.Client.Stylesheets
         public const string StyleClassLabelSmall = "LabelSmall";
         public const string StyleClassButtonBig = "ButtonBig";
 
-        public const string StyleClassButtonHelp = "HelpButton";
-
         public const string StyleClassPopupMessageSmall = "PopupMessageSmall";
         public const string StyleClassPopupMessageSmallCaution = "PopupMessageSmallCaution";
         public const string StyleClassPopupMessageMedium = "PopupMessageMedium";
@@ -1341,10 +1339,6 @@ namespace Content.Client.Stylesheets
                     new StyleProperty(PanelContainer.StylePropertyPanel, new StyleBoxFlat { BackgroundColor = NanoGold, ContentMarginBottomOverride = 2, ContentMarginLeftOverride = 2}),
                 }),
 
-                Element<TextureButton>()
-                    .Class(StyleClassButtonHelp)
-                    .Prop(TextureButton.StylePropertyTexture, resCache.GetTexture("/Textures/Interface/VerbIcons/information.svg.192dpi.png")),
-
                 // Labels ---
                 Element<Label>().Class(StyleClassLabelBig)
                     .Prop(Label.StylePropertyFont, notoSans16),