Skip to content

Commit

Permalink
Update ResinPanel.tsx
Browse files Browse the repository at this point in the history
convert to the new version
  • Loading branch information
Doubleumc committed Jul 25, 2024
1 parent 79bfc68 commit 02af80f
Showing 1 changed file with 10 additions and 8 deletions.
18 changes: 10 additions & 8 deletions tgui/packages/tgui/interfaces/ResinPanel.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { BooleanLike, classes } from 'common/react';
import { useBackend } from 'tgui/backend';
import { Box, Button, Dropdown, Section, Stack, Tabs } from 'tgui/components';
import { Window } from 'tgui/layouts';
import { BooleanLike, classes } from 'common/react';

interface ResinPanelData {
structure_list: StructureEntry[];
Expand Down Expand Up @@ -34,7 +34,8 @@ export const ResinPanel = () => {
width={350}
height={15 + structure_list.length * 80}
title="Resin Panel"
theme="admin">
theme="admin"
>
<Window.Content>
<Section
title="Resin"
Expand All @@ -43,10 +44,11 @@ export const ResinPanel = () => {
<Stack.Item>
<Button
selected={build_click_intercept}
content="Click Build"
tooltip="LMB to place, MMB to remove"
onClick={() => act('toggle_build_click_intercept')}
/>
>
Click Build
</Button>
</Stack.Item>
<Stack.Item>
<Dropdown
Expand All @@ -61,15 +63,15 @@ export const ResinPanel = () => {
</Stack>
}
scrollable
fill>
fill
>
<Tabs vertical fluid fill>
{structure_list.map((item, index) => (
<Tabs.Tab
key={index}
selected={item.id === selected_structure}
onClick={() =>
act('set_selected_structure', { type: item.id })
}>
onClick={() => act('set_selected_structure', { type: item.id })}
>
<Stack align="center">
<Stack.Item>
<span
Expand Down

0 comments on commit 02af80f

Please sign in to comment.