Ich habe den Desktop-Overflow jetzt an der eigentlichen Ursache angefasst in dashboard-shell.tsx. Die Übersicht ist nicht mehr gleichzeitig Flex-Layout und Scroll-Container, sondern hat jetzt einen sauberen äußeren Scroll-Wrapper plus inneren max-content-Track. Zusätzlich schrumpft die rechte Desktop-Spalte jetzt korrekt mit flex: 1 1 0%, damit sie keinen zweiten Seiten-Overflow mehr erzeugt
This commit is contained in:
@@ -1959,23 +1959,51 @@ export function DashboardShell({
|
||||
</Card>
|
||||
) : null}
|
||||
|
||||
<Stack
|
||||
direction={isCompactLayout ? "column" : "row"}
|
||||
gap={2}
|
||||
{isCompactLayout ? (
|
||||
<Stack direction="column" gap={2} sx={{ width: "100%", minWidth: 0 }}>
|
||||
{(mobileSelectedGroup ? [mobileSelectedGroup] : []).map((group) => (
|
||||
<Box key={group.id} sx={{ width: "100%", minWidth: 0 }}>
|
||||
<BudgetColumn
|
||||
group={group}
|
||||
viewer={viewer}
|
||||
busy={busy}
|
||||
approvalThreshold={approvalThreshold}
|
||||
onApprove={handleApprove}
|
||||
onMarkPaid={handleMarkPaid}
|
||||
onDocument={handleDocument}
|
||||
onSaveWorkingGroup={handleSaveWorkingGroup}
|
||||
onDeleteWorkingGroup={handleDeleteWorkingGroup}
|
||||
onSaveBudget={handleSaveBudget}
|
||||
onDeleteBudget={handleDeleteBudget}
|
||||
onDeleteExpense={handleDeleteExpense}
|
||||
/>
|
||||
</Box>
|
||||
))}
|
||||
</Stack>
|
||||
) : (
|
||||
<Box
|
||||
sx={{
|
||||
width: "100%",
|
||||
minWidth: 0,
|
||||
maxWidth: "100%",
|
||||
overflowX: isCompactLayout ? "visible" : "auto",
|
||||
overflowX: "auto",
|
||||
overflowY: "hidden",
|
||||
pb: isCompactLayout ? 0 : 2,
|
||||
alignItems: "stretch",
|
||||
scrollSnapType: isCompactLayout ? "none" : "x proximity",
|
||||
scrollbarGutter: isCompactLayout ? "auto" : "stable both-edges",
|
||||
pb: 2,
|
||||
scrollbarGutter: "stable both-edges",
|
||||
overscrollBehaviorX: "contain"
|
||||
}}
|
||||
>
|
||||
{(isCompactLayout ? (mobileSelectedGroup ? [mobileSelectedGroup] : []) : visibleGroups).map((group) => (
|
||||
<Stack
|
||||
direction="row"
|
||||
gap={2}
|
||||
sx={{
|
||||
width: "max-content",
|
||||
minWidth: "100%",
|
||||
alignItems: "stretch",
|
||||
pr: 0.5
|
||||
}}
|
||||
>
|
||||
{visibleGroups.map((group) => (
|
||||
<Box key={group.id} sx={{ flex: "0 0 auto", scrollSnapAlign: "start" }}>
|
||||
<BudgetColumn
|
||||
group={group}
|
||||
@@ -1994,14 +2022,21 @@ export function DashboardShell({
|
||||
</Box>
|
||||
))}
|
||||
</Stack>
|
||||
</Box>
|
||||
)}
|
||||
</Stack>
|
||||
);
|
||||
|
||||
const desktopSectionContent =
|
||||
desktopSection === "overview" ? (
|
||||
<Stack direction={{ xs: "column", xl: "row" }} gap={3} alignItems="flex-start" sx={{ minWidth: 0 }}>
|
||||
<Stack
|
||||
direction={{ xs: "column", xl: "row" }}
|
||||
gap={3}
|
||||
alignItems="flex-start"
|
||||
sx={{ width: "100%", minWidth: 0, overflowX: "hidden" }}
|
||||
>
|
||||
<Box sx={{ width: { xs: "100%", xl: 380 }, flexShrink: 0 }}>{actionCards}</Box>
|
||||
<Box sx={{ flex: 1, minWidth: 0, maxWidth: "100%", overflowX: "hidden" }}>{overviewContent}</Box>
|
||||
<Box sx={{ flex: "1 1 0%", minWidth: 0, maxWidth: "100%", overflowX: "hidden" }}>{overviewContent}</Box>
|
||||
</Stack>
|
||||
) : desktopSection === "periods" ? (
|
||||
<Stack direction={{ xs: "column", xl: "row" }} gap={3} alignItems="flex-start">
|
||||
|
||||
Reference in New Issue
Block a user