fix: HTML exports have extra empty page, closes #6205
This commit is contained in:
@@ -261,16 +261,6 @@ const emailStyle = (props: Props) => css`
|
||||
}
|
||||
`;
|
||||
|
||||
const printStyle = (props: Props) => css`
|
||||
${props.staticHTML &&
|
||||
`
|
||||
body {
|
||||
height: auto;
|
||||
min-height: 0;
|
||||
}
|
||||
`}
|
||||
`;
|
||||
|
||||
const style = (props: Props) => `
|
||||
flex-grow: ${props.grow ? 1 : 0};
|
||||
justify-content: start;
|
||||
@@ -1570,7 +1560,6 @@ const EditorContainer = styled.div<Props>`
|
||||
${codeBlockStyle}
|
||||
${findAndReplaceStyle}
|
||||
${emailStyle}
|
||||
${printStyle}
|
||||
`;
|
||||
|
||||
export default EditorContainer;
|
||||
|
||||
@@ -3,6 +3,7 @@ import styledNormalize from "styled-normalize";
|
||||
import { breakpoints, depths, s } from ".";
|
||||
|
||||
type Props = {
|
||||
staticHTML?: boolean;
|
||||
useCursorPointer?: boolean;
|
||||
};
|
||||
|
||||
@@ -16,7 +17,7 @@ export default createGlobalStyle<Props>`
|
||||
html,
|
||||
body {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
height: ${(props) => (props.staticHTML ? "0" : "100%")};
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
print-color-adjust: exact;
|
||||
@@ -46,7 +47,7 @@ export default createGlobalStyle<Props>`
|
||||
@media (min-width: ${breakpoints.tablet}px) {
|
||||
html,
|
||||
body {
|
||||
min-height: 100vh;
|
||||
min-height: ${(props) => (props.staticHTML ? "0" : "100vh")};
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user