Skip to content

Commit 3bc1e7f

Browse files
Cleanup panel groups (#9783)
- Hide label if panel is not expanded - Add a visual divider
1 parent 26b5f0a commit 3bc1e7f

File tree

2 files changed

+10
-7
lines changed

2 files changed

+10
-7
lines changed

src/frontend/src/components/panels/PanelGroup.tsx

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -218,13 +218,16 @@ function BasePanelGroup({
218218
{groupedPanels.map((group) => (
219219
<Box key={`group-${group.id}`} w={'100%'}>
220220
<Text
221-
fs={'italic'}
222-
ml={'1rem'}
221+
hidden={!group.label || !expanded}
223222
c={vars.colors.primaryColors[7]}
224223
key={`group-label-${group.id}`}
224+
style={{
225+
paddingLeft: '10px'
226+
}}
225227
>
226228
{group.label}
227229
</Text>
230+
{group.label && <Divider c={vars.colors.primaryColors[7]} />}
228231
{group.panels?.map(
229232
(panel) =>
230233
!panel.hidden && (

src/frontend/src/pages/Index/Settings/AdminCenter/Index.tsx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -256,11 +256,6 @@ export default function AdminCenter() {
256256
label: t`Reporting`,
257257
panelIDs: ['labels', 'reports']
258258
},
259-
{
260-
id: 'extend',
261-
label: t`Extend / Integrate`,
262-
panelIDs: ['plugin', 'machine']
263-
},
264259
{
265260
id: 'plm',
266261
label: t`PLM`,
@@ -270,6 +265,11 @@ export default function AdminCenter() {
270265
'location-types',
271266
'stocktake'
272267
]
268+
},
269+
{
270+
id: 'extend',
271+
label: t`Extend / Integrate`,
272+
panelIDs: ['plugin', 'machine']
273273
}
274274
];
275275
}, []);

0 commit comments

Comments
 (0)