From 16309bfefe4e20ea0dd7260e1a7c727ff1499e18 Mon Sep 17 00:00:00 2001
From: John Willard <53777086+JohnFulpWillard@users.noreply.github.com>
Date: Sat, 11 Jan 2025 21:32:11 -0500
Subject: [PATCH] Fixes broken instances of overflowY for 516 (#89022)
## About The Pull Request
After updating to 516, I tried messing around with some stuff, and found
the Uplink didn't have a scrollbar. Looking into it, I noticed 515 still
had it, so I looked at what was giving it the scrollbar in the first
place, ``overflowY``, and (with the great help of Aylong) found it was a
problem with the individual UIs using it.
Therefore, I went through all instances of it to make sure they work,
here's all UIs that broke, and what I did.
- Oresilo: Replaced with ``scrollable``, also made it a Section instead
of a Box.
- PersonalCrafting: Uses it twice, first one works as intended, second
one doesn't. Updated to work & changed the UI a bit. Video demonstration
below
- TelecommsMonitor: Replaced with ``scrollable``.
- GenericUplink: Replaced with ``scrollable``, no longer uses auto, so
it's always 'scrollable' even if it's on compact mode.
I changed the Crafting UI so the buttons at the bottom left don't get
cropped out anymore, making good use of our scrollable element.
Before:
https://github.com/user-attachments/assets/de074634-4bb9-4013-ac65-869b05fce2cc
After:
https://github.com/user-attachments/assets/e20a7377-69d2-41d1-a042-f79194dcc6f7
Though this doesn't really do anything, I did test this on 515 just to
be 100% sure nothing breaks.
## Why It's Good For The Game
Scrolling works in these few instances on 516 now, few less things to
deal with later.
I think it's better to use scrollable where ``overflowY`` is not needed
because it's what we use more so it's easier to spot when it breaks in
the future.
## Changelog
:cl:
fix: Fixed the ability to scroll for Ore silo's logging, personal
crafting's material section, telecomms monitors, and traitor uplinks for
clients on 516.
/:cl:
---
tgui/packages/tgui/interfaces/OreSilo.tsx | 4 +-
.../tgui/interfaces/PersonalCrafting.tsx | 5 +-
.../tgui/interfaces/TelecommsMonitor.tsx | 3 +-
.../tgui/interfaces/Uplink/GenericUplink.tsx | 177 +++++++++---------
4 files changed, 97 insertions(+), 92 deletions(-)
diff --git a/tgui/packages/tgui/interfaces/OreSilo.tsx b/tgui/packages/tgui/interfaces/OreSilo.tsx
index 32f4988a98a..696ecdf18d4 100644
--- a/tgui/packages/tgui/interfaces/OreSilo.tsx
+++ b/tgui/packages/tgui/interfaces/OreSilo.tsx
@@ -210,13 +210,13 @@ const LogsList = (props: LogsListProps) => {
const { logs } = props;
return logs.length > 0 ? (
-
+
{logs.map((log, index) => (
))}
-
+
) : (
No log entries currently present!
);
diff --git a/tgui/packages/tgui/interfaces/PersonalCrafting.tsx b/tgui/packages/tgui/interfaces/PersonalCrafting.tsx
index 3710a89855b..104c2b0d04f 100644
--- a/tgui/packages/tgui/interfaces/PersonalCrafting.tsx
+++ b/tgui/packages/tgui/interfaces/PersonalCrafting.tsx
@@ -264,6 +264,7 @@ export const PersonalCrafting = (props) => {
{
-
-
+
+
{tabMode === TABS.foodtype &&
mode === MODE.cooking &&
diff --git a/tgui/packages/tgui/interfaces/TelecommsMonitor.tsx b/tgui/packages/tgui/interfaces/TelecommsMonitor.tsx
index 33329333e02..a4904017694 100644
--- a/tgui/packages/tgui/interfaces/TelecommsMonitor.tsx
+++ b/tgui/packages/tgui/interfaces/TelecommsMonitor.tsx
@@ -161,6 +161,7 @@ const MachineList = (props: MachineListProps) => {
return (
{
{sortedMachines.length > 0 ? (
-
+
{sortedMachines.map((machine, index) => (
- }
+ height={compactMode ? '32px' : '64px'}
+ position="relative"
+ m={compactMode ? '2px' : 0}
+ mr={1}
>
-
+
+
+
+ {compactMode ? (
+
+
+ {item.name}
+
+
+
+
+
+
+
+ handleBuy(item)}
+ >
+ {item.cost}
+
+
+
+ ) : (
+ handleBuy(item)}
+ >
+ {item.cost}
+
+ }
>
- {item.desc}
-
-
- )}
-
-
-
-
- ))}
-
+
+ {item.desc}
+
+
+ )}
+
+
+
+
+ ))}
+
+
);
};