]> git.smokeofanarchy.ru Git - space-station-14.git/commitdiff
Rename "Inset" style, implement in sheetlets (#41975)
authoreoineoineoin <helloworld@eoinrul.es>
Mon, 19 Jan 2026 23:27:42 +0000 (23:27 +0000)
committerGitHub <noreply@github.com>
Mon, 19 Jan 2026 23:27:42 +0000 (23:27 +0000)
* Rename "Inset" style, implement in sheetlets

* Remove from StyleNano

Content.Client/Anomaly/Ui/AnomalyGeneratorWindow.xaml
Content.Client/Atmos/Monitor/UI/AirAlarmWindow.xaml
Content.Client/CloningConsole/UI/CloningConsoleWindow.xaml
Content.Client/Power/APC/UI/ApcMenu.xaml
Content.Client/Power/Battery/BatteryMenu.xaml
Content.Client/Power/Generator/GeneratorWindow.xaml
Content.Client/Power/PowerCharge/PowerChargeWindow.xaml
Content.Client/Stylesheets/Sheetlets/PanelSheetlet.cs
Content.Client/Stylesheets/StyleClass.cs
Content.Client/Stylesheets/StyleNano.cs

index 88df194ecb106fac3dcf3df420556ad01c1d728c..269b44f62c451f1dc877260617be19567e015135 100644 (file)
@@ -1,4 +1,4 @@
-<controls:FancyWindow xmlns="https://spacestation14.io"
+<controls:FancyWindow xmlns="https://spacestation14.io"
                 xmlns:controls="clr-namespace:Content.Client.UserInterface.Controls"
                 Title="{Loc 'anomaly-generator-ui-title'}"
 
@@ -32,7 +32,7 @@
             </BoxContainer>
             <!--Sprite View-->
             <PanelContainer Margin="12 0 0 0"
-                            StyleClasses="Inset"
+                            StyleClasses="BackgroundPanelDark"
                             VerticalAlignment="Center">
                 <SpriteView Name="EntityView"
                             SetSize="96 96"
index f0dc29facfe9d8f2b0252f1d9dac20c1acd3a141..dc547dda6b1067f68929b09e93e3db03824ddc03 100644 (file)
@@ -7,7 +7,7 @@
         <!-- Status (pressure, temperature, alarm state, device total, address, etc) -->
         <BoxContainer Orientation="Horizontal" Margin="0 0 0 2">
             <!-- Left column (view of entity) -->
-            <PanelContainer Margin="2 0 6 0" StyleClasses="Inset" VerticalAlignment="Center" VerticalExpand="True">
+            <PanelContainer Margin="2 0 6 0" StyleClasses="BackgroundPanelDark" VerticalAlignment="Center" VerticalExpand="True">
                 <SpriteView Name="EntityView" OverrideDirection="South" Scale="2 2" SetSize="64 64"/>
             </PanelContainer>
             <!-- Center column (pressure, temperature, alarm state) -->
index f08b94c7ac410f14ca4217daffdf30209c96a9a8..f4447fce0bf49a8216fdaf4bad11bb3cab3a2a66 100644 (file)
@@ -8,7 +8,7 @@
                       VerticalExpand="True"
                       HorizontalExpand="True"
                       MinSize="100 150">
-            <PanelContainer VerticalExpand="True" StyleClasses="Inset">
+            <PanelContainer VerticalExpand="True" StyleClasses="BackgroundPanelDark">
                 <BoxContainer Name="GeneticScannerContents" Margin="5 5 5 5" Orientation="Vertical" VerticalExpand="True" HorizontalExpand="True">
                     <Label HorizontalAlignment="Center" Text="{Loc 'cloning-console-window-scanner-details-label'}" />
                     <BoxContainer Orientation="Horizontal" VerticalExpand="True" HorizontalExpand="True">
@@ -35,7 +35,7 @@
                 </BoxContainer>
             </PanelContainer>
             <Control MinSize="50 5" />
-            <PanelContainer VerticalExpand="True" StyleClasses="Inset">
+            <PanelContainer VerticalExpand="True" StyleClasses="BackgroundPanelDark">
                 <BoxContainer Name="CloningPodContents" Margin="5 5 5 5" Orientation="Vertical" VerticalExpand="True" HorizontalExpand="True">
                     <Label HorizontalAlignment="Center" Text="{Loc 'cloning-console-window-pod-details-label'}" />
                     <BoxContainer Orientation="Vertical" VerticalExpand="True" HorizontalExpand="True">
index 682aea55d2ab821115ac4f900ea21b7ba940889b..7dd38c76fcb06dc0258a53b48fd793c3eb18675e 100644 (file)
@@ -1,4 +1,4 @@
-<controls:FancyWindow  xmlns="https://spacestation14.io"
+<controls:FancyWindow  xmlns="https://spacestation14.io"
     xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
     xmlns:controls="clr-namespace:Content.Client.UserInterface.Controls"
     xmlns:style="clr-namespace:Content.Client.Stylesheets"
@@ -10,7 +10,7 @@
         <BoxContainer Margin="0 5 10 10" Orientation="Vertical">
             <BoxContainer Margin="0" Orientation="Horizontal">
                 <!-- Sprite View -->
-                <PanelContainer Margin="0" StyleClasses="Inset" VerticalAlignment="Center">
+                <PanelContainer Margin="0" StyleClasses="BackgroundPanelDark" VerticalAlignment="Center">
                     <SpriteView Name="EntityView" Scale="2 2" SetSize="64 64" OverrideDirection="South" />
                 </PanelContainer>
                 <!-- Data -->
index 83483a517e3090d823106d0fcc101a7eb850771d..3602126cd450f3310033294326a03f90f73ee971 100644 (file)
@@ -1,4 +1,4 @@
-<controls:FancyWindow xmlns="https://spacestation14.io"
+<controls:FancyWindow xmlns="https://spacestation14.io"
                       xmlns:controls="clr-namespace:Content.Client.UserInterface.Controls"
                       xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
                       xmlns:gfx="clr-namespace:Robust.Client.Graphics;assembly=Robust.Client"
@@ -16,7 +16,7 @@
                                     Margin="2 16" />
 
                     <!-- Box with breaker, label, values -->
-                    <PanelContainer HorizontalExpand="True" StyleClasses="Inset">
+                    <PanelContainer HorizontalExpand="True" StyleClasses="BackgroundPanelDark">
                         <BoxContainer Orientation="Vertical">
                             <BoxContainer Orientation="Horizontal">
                                 <Label Text="{Loc 'battery-menu-in'}" HorizontalExpand="True" VerticalAlignment="Top"
@@ -46,7 +46,7 @@
                                     Margin="2 16" />
 
                     <!-- Box with breaker, label, values -->
-                    <PanelContainer HorizontalExpand="True" StyleClasses="Inset">
+                    <PanelContainer HorizontalExpand="True" StyleClasses="BackgroundPanelDark">
                         <BoxContainer Orientation="Vertical">
                             <BoxContainer Orientation="Horizontal">
                                 <Label Text="{Loc 'battery-menu-out'}" HorizontalExpand="True" VerticalAlignment="Top"
@@ -69,7 +69,7 @@
             <!-- Middle pane: charge/discharge -->
             <BoxContainer Name="ChargeDischarge" Orientation="Vertical" HorizontalExpand="True">
                 <!-- Charge -->
-                <PanelContainer VerticalExpand="True" StyleClasses="Inset" Margin="0 0 0 8">
+                <PanelContainer VerticalExpand="True" StyleClasses="BackgroundPanelDark" Margin="0 0 0 8">
                     <BoxContainer Orientation="Vertical">
                         <Label Text="{Loc 'battery-menu-charge-header'}" StyleClasses="LabelKeyText" />
                         <BoxContainer Orientation="Vertical" VerticalExpand="True" VerticalAlignment="Center">
@@ -86,7 +86,7 @@
                     </BoxContainer>
                 </PanelContainer>
                 <!-- Discharge -->
-                <PanelContainer VerticalExpand="True" StyleClasses="Inset">
+                <PanelContainer VerticalExpand="True" StyleClasses="BackgroundPanelDark">
                     <BoxContainer Orientation="Vertical">
                         <Label Text="{Loc 'battery-menu-discharge-header'}" StyleClasses="LabelKeyText" />
                         <BoxContainer Orientation="Vertical" VerticalExpand="True" VerticalAlignment="Center">
             </BoxContainer>
 
             <!-- Right pane: storage -->
-            <PanelContainer Name="Storage" StyleClasses="Inset" HorizontalExpand="True">
+            <PanelContainer Name="Storage" StyleClasses="BackgroundPanelDark" HorizontalExpand="True">
                 <BoxContainer Orientation="Vertical">
                     <Label Text="{Loc 'battery-menu-storage-header'}" StyleClasses="LabelKeyText" />
                     <GridContainer Columns="2">
index 85127a96448a2f74c870bfd209f948b1bb17a688..f59e07a131c5fa23601483d8fc21b19aaecf7cb6 100644 (file)
@@ -1,4 +1,4 @@
-<controls:FancyWindow xmlns="https://spacestation14.io"
+<controls:FancyWindow xmlns="https://spacestation14.io"
                 xmlns:cc="clr-namespace:Content.Client.Administration.UI.CustomControls"
                 xmlns:controls="clr-namespace:Content.Client.UserInterface.Controls"
                 MinSize="450 250"
@@ -41,7 +41,7 @@
             <Label Margin="2 0 0 0" Name="CloggedLabel" FontColorOverride="Red" Text="{Loc 'portable-generator-ui-clogged'}" />
         </BoxContainer>
         <cc:VSeparator StyleClasses="LowDivider"/>
-        <PanelContainer Margin="12 0 0 0" StyleClasses="Inset" VerticalAlignment="Center">
+        <PanelContainer Margin="12 0 0 0" StyleClasses="BackgroundPanelDark" VerticalAlignment="Center">
             <SpriteView Name="EntityView" SetSize="64 64" Scale="2 2" OverrideDirection="South" Margin="15"/>
         </PanelContainer>
     </BoxContainer>
index 632126ba07b18cd6d90cce21f9f7efe1fbb9a991..4c17c0a5f5aae8b069d84fc6aa2a82980190ac1c 100644 (file)
@@ -1,4 +1,4 @@
-<controls:FancyWindow
+<controls:FancyWindow
     xmlns="https://spacestation14.io"
     xmlns:controls="clr-namespace:Content.Client.UserInterface.Controls"
     MinSize="320 180"
@@ -76,7 +76,7 @@
             </GridContainer>
         </BoxContainer>
         <PanelContainer
-            StyleClasses="Inset"
+            StyleClasses="BackgroundPanelDark"
             VerticalAlignment="Top">
 
             <SpriteView Name="EntityView"
index 64ce2e53566db0a5316a068849e8874cfd0d0596..d4d2114054c55624e1e13fadf0274a61d5a43769 100644 (file)
@@ -45,6 +45,10 @@ public sealed class PanelSheetlet<T> : Sheetlet<T> where T : PalettedStylesheet,
                 .Prop(PanelContainer.StylePropertyPanel, StyleBoxHelpers.BaseStyleBox(sheet))
                 .Modulate(sheet.SecondaryPalette.Background),
             E()
+                .Class(StyleClass.BackgroundPanelDark)
+                .Prop(PanelContainer.StylePropertyPanel, StyleBoxHelpers.BaseStyleBox(sheet))
+                .Modulate(sheet.SecondaryPalette.BackgroundDark),
+             E()
                 .Class(StyleClass.BackgroundPanelOpenLeft)
                 .Prop(PanelContainer.StylePropertyPanel, StyleBoxHelpers.OpenLeftStyleBox(sheet))
                 .Modulate(sheet.SecondaryPalette.Background),
index e5fde69584cc728e55d40a44902cb525aea08b32..e569824b76359b91eb8bac82fb9c0e39a3e4b844 100644 (file)
@@ -45,6 +45,7 @@ public static class StyleClass
     public const string LabelMonospaceSubHeading = "ConsoleSubHeading";
 
     public const string BackgroundPanel = "BackgroundPanel"; // replaces `AngleRect`
+    public const string BackgroundPanelDark = "BackgroundPanelDark"; // replaces `Inset`
     public const string BackgroundPanelOpenLeft = "BackgroundPanelOpenLeft"; // replaces `BackgroundOpenLeft`
     public const string BackgroundPanelOpenRight = "BackgroundPanelOpenRight"; // replaces `BackgroundOpenRight`
 
index 01b666a4b04867b34443920674e6090db7d82399..52c340dada1c1dfae8fd41719663fcadc4b1e13f 100644 (file)
@@ -67,7 +67,6 @@ namespace Content.Client.Stylesheets
         public const string StyleClassChatChannelSelectorButton = "chatSelectorOptionButton";
         public const string StyleClassChatFilterOptionButton = "chatFilterOptionButton";
         public const string StyleClassStorageButton = "storageButton";
-        public const string StyleClassInset = "Inset";
 
         public const string StyleClassConsoleHeading = "ConsoleHeading";
         public const string StyleClassConsoleSubHeading = "ConsoleSubHeading";
@@ -531,13 +530,6 @@ namespace Content.Client.Stylesheets
 
             var boxFont13 = resCache.GetFont("/Fonts/Boxfont-round/Boxfont Round.ttf", 13);
 
-            var insetBack = new StyleBoxTexture
-            {
-                Texture = buttonTex,
-                Modulate = Color.FromHex("#202023"),
-            };
-            insetBack.SetPatchMargin(StyleBox.Margin.All, 10);
-
             // Default paper background:
             var paperBackground = new StyleBoxTexture
             {
@@ -1625,10 +1617,6 @@ namespace Content.Client.Stylesheets
                 // Silicon law edit ui
                 Element<Label>().Class(SiliconLawContainer.StyleClassSiliconLawPositionLabel)
                     .Prop(Label.StylePropertyFontColor, NanoGold),
-
-                Element<PanelContainer>()
-                    .Class(StyleClassInset)
-                    .Prop(PanelContainer.StylePropertyPanel, insetBack),
             }).ToList());
         }
     }