Skip to content

Commit

Permalink
height hot fix
Browse files Browse the repository at this point in the history
  • Loading branch information
lifeparticle committed Sep 7, 2023
1 parent 5498d53 commit 5a8e03c
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 9 deletions.
14 changes: 10 additions & 4 deletions ui/src/pages/Markdown/TableOfContent/TableOfContent.module.scss
Original file line number Diff line number Diff line change
@@ -1,10 +1,16 @@
.toc {
height: calc(100dvh - 70px);
overflow: hidden;

&__output,
&__input {
height: calc(100dvh - 75px);
}

&__output {
display: grid;
gap: var(--bt-size-30);
margin-top: var(--bt-size-24);
&_form {
display: grid;
gap: var(--bt-size-30);
margin-top: var(--bt-size-24);
}
}
}
19 changes: 14 additions & 5 deletions ui/src/pages/Markdown/TableOfContent/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ const TableOfContent: React.FC = () => {

return (
<PageGrid className={style.toc}>
<Card>
<Card className={style.toc__input}>
<Form layout="vertical">
<CopyInput>
<ResponsiveInputWithLabel
Expand All @@ -115,26 +115,35 @@ const TableOfContent: React.FC = () => {
</CopyInput>
<Form.Item label="Content">
<TextArea
style={{
height: "calc(100dvh - 250px)",
}}
placeholder=""
value={markdown}
onChange={(event) =>
onMarkdownChange(event.currentTarget.value)
}
rows={10}
autoSize={false}
/>
</Form.Item>
</Form>
</Card>

<Card>
<Form layout="vertical" className={style.toc__output}>
<Card className={style.toc__output}>
<Form layout="vertical" className={style.toc__output_form}>
<Clipboard
text={tableOfContents}
clipboardComponent={ClipboardButton}
/>

<Form.Item label="Output">
<TextArea value={tableOfContents} rows={10} />
<TextArea
value={tableOfContents}
style={{
height: "calc(100dvh - 250px)",
}}
autoSize={false}
/>
</Form.Item>
</Form>
</Card>
Expand Down

0 comments on commit 5a8e03c

Please sign in to comment.