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

CSSTUDIO-2728: Keep scroll position after poll + allow scrolling on e… #163

Merged
merged 1 commit into from
Nov 1, 2024
Merged
Show file tree
Hide file tree
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
18 changes: 5 additions & 13 deletions src/beta/components/log/LogDetails/LogDetails.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,32 +12,24 @@ const LogDetails = ({ log, className }) => {
<Stack
className={`LogDetails ${className}`}
gap={1}
padding={2}
pb={4}
p={2}
sx={{
overflow: "scroll"
}}
>
<LogAttachmentsHeader log={log} />
<Typography component="h2" variant="h4" fontWeight="600" mb={2}>{log.title}</Typography>
<Typography sx={{ fontSize: "1.6rem" }} component="h2" fontWeight="600" mb={1}>{log.title}</Typography>
{log.source && (
<>
<Divider />
<CommonmarkPreview commonmarkSrc={log.source} imageUrlPrefix={customization.APP_BASE_URL + "/"} />
</>
<CommonmarkPreview commonmarkSrc={log.source} imageUrlPrefix={customization.APP_BASE_URL + "/"} />
)}
{log?.properties && filteredProperties.length > 0 && (
<Box sx={{
"& > div:last-child, & > div.Mui-expanded:last-child": {
marginBottom: "20px"
},
}}>
<Box mt={2}>
{filteredProperties.map((it, i) =>
<LogProperty property={it} key={`${it.name}-${i}`} />
)}
</Box>
)}
<Divider sx={{ marginBottom: "20px" }} />
<Divider sx={{ margin: "20px 0" }} />
<MetadataTable log={log} />
</Stack >
);
Expand Down
4 changes: 2 additions & 2 deletions src/beta/components/log/LogDetails/LogDetailsWithReplies.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,8 @@ const LogDetailsWithReplies = ({ log }) => {
}

return (
<Stack>
<Box padding={2}>
<Stack sx={{ height: "100%", overflow: "auto" }}>
<Box padding={2} bgcolor={"grey.100"}>
<LogHeader log={log} />
</Box>
<LogDetails log={log} />
Expand Down
4 changes: 2 additions & 2 deletions src/beta/components/search/SearchResults.js
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ export const SearchResults = styled(({ className }) => {
hitCount: 0
},
error,
isFetching: loading
isLoading: loading
} = ologApi.endpoints.searchLogs.useQuery(
searchLogsQuery,
{
Expand Down Expand Up @@ -144,7 +144,7 @@ export const SearchResults = styled(({ className }) => {
</Stack>
</Stack>
</Box>
{loading ? <LinearProgress /> : null}
{loading && <LinearProgress />}
{error ?
<Box>
<Alert severity="error">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ const StyledHtmlContent = styled(HtmlContent)`
padding: 0;
& > p {
padding: 0;
margin: 0;
}
width: 100%;
font-size: 1.2rem;
Expand Down
Loading