Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Split component to allow sampler output view to take up more vertical space #252

Merged
merged 1 commit into from
Dec 4, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 7 additions & 6 deletions gui/src/app/pages/HomePage/SamplingWindow/SamplingWindow.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { FunctionComponent, useCallback, useContext } from "react";

import { Split } from "@geoffcox/react-splitter";
import Box from "@mui/material/Box";
import Divider from "@mui/material/Divider";
import Grid from "@mui/material/Grid";
import { CompileContext } from "@SpCompilation/CompileContext";
import RunPanel from "@SpComponents/RunPanel";
Expand Down Expand Up @@ -36,7 +36,7 @@ const SamplingWindow: FunctionComponent<SamplingWindowProps> = () => {
const { sampler, latestRun } = useStanSampler(compiledMainJsUrl);
const isSampling = latestRun.status === "sampling";
return (
<Box height="100%" display="flex" flexDirection="column">
<Split horizontal initialPrimarySize="30%" minSecondarySize="10%">
<Grid container>
<Grid item xs={12} sm={4}>
<SamplingOptsPanel
Expand All @@ -54,11 +54,12 @@ const SamplingWindow: FunctionComponent<SamplingWindowProps> = () => {
/>
</Grid>
</Grid>
<Divider />
<Box flex="1" overflow="hidden">
<SamplingResultsArea latestRun={latestRun} />
<Box height="100%" display="flex" flexDirection="column">
<Box flex="1" overflow="hidden">
<SamplingResultsArea latestRun={latestRun} />
</Box>
</Box>
</Box>
</Split>
);
};

Expand Down
Loading