mirror of
https://github.com/inventree/InvenTree.git
synced 2025-06-17 04:25:42 +00:00
Cleanup panel groups (#9783)
- Hide label if panel is not expanded - Add a visual divider
This commit is contained in:
@ -218,13 +218,16 @@ function BasePanelGroup({
|
|||||||
{groupedPanels.map((group) => (
|
{groupedPanels.map((group) => (
|
||||||
<Box key={`group-${group.id}`} w={'100%'}>
|
<Box key={`group-${group.id}`} w={'100%'}>
|
||||||
<Text
|
<Text
|
||||||
fs={'italic'}
|
hidden={!group.label || !expanded}
|
||||||
ml={'1rem'}
|
|
||||||
c={vars.colors.primaryColors[7]}
|
c={vars.colors.primaryColors[7]}
|
||||||
key={`group-label-${group.id}`}
|
key={`group-label-${group.id}`}
|
||||||
|
style={{
|
||||||
|
paddingLeft: '10px'
|
||||||
|
}}
|
||||||
>
|
>
|
||||||
{group.label}
|
{group.label}
|
||||||
</Text>
|
</Text>
|
||||||
|
{group.label && <Divider c={vars.colors.primaryColors[7]} />}
|
||||||
{group.panels?.map(
|
{group.panels?.map(
|
||||||
(panel) =>
|
(panel) =>
|
||||||
!panel.hidden && (
|
!panel.hidden && (
|
||||||
|
@ -256,11 +256,6 @@ export default function AdminCenter() {
|
|||||||
label: t`Reporting`,
|
label: t`Reporting`,
|
||||||
panelIDs: ['labels', 'reports']
|
panelIDs: ['labels', 'reports']
|
||||||
},
|
},
|
||||||
{
|
|
||||||
id: 'extend',
|
|
||||||
label: t`Extend / Integrate`,
|
|
||||||
panelIDs: ['plugin', 'machine']
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
id: 'plm',
|
id: 'plm',
|
||||||
label: t`PLM`,
|
label: t`PLM`,
|
||||||
@ -270,6 +265,11 @@ export default function AdminCenter() {
|
|||||||
'location-types',
|
'location-types',
|
||||||
'stocktake'
|
'stocktake'
|
||||||
]
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 'extend',
|
||||||
|
label: t`Extend / Integrate`,
|
||||||
|
panelIDs: ['plugin', 'machine']
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
}, []);
|
}, []);
|
||||||
|
Reference in New Issue
Block a user