fix headings

This commit is contained in:
Philipinho
2026-03-03 14:17:51 +00:00
parent b6478fee84
commit 568dd4c321
3 changed files with 54 additions and 16 deletions
@@ -66,12 +66,14 @@ export default function ReadonlyPageEditor({
return ( return (
<> <>
<div className="page-title">
<EditorProvider <EditorProvider
editable={false} editable={false}
immediatelyRender={true} immediatelyRender={true}
extensions={titleExtensions} extensions={titleExtensions}
content={title} content={title}
></EditorProvider> ></EditorProvider>
</div>
<EditorProvider <EditorProvider
editable={false} editable={false}
@@ -52,7 +52,34 @@
h1, h1,
h2, h2,
h3, h3 {
letter-spacing: -0.01em;
line-height: 1.2;
font-weight: 600;
margin-bottom: 0;
}
h1 strong,
h2 strong,
h3 strong {
font-weight: 600;
}
h1 {
font-size: 1.875rem;
margin-top: 1.875rem;
}
h2 {
font-size: 1.5rem;
margin-top: 1.5rem;
}
h3 {
font-size: 1.25rem;
margin-top: 1.25rem;
}
h4, h4,
h5, h5,
h6 { h6 {
@@ -243,3 +270,10 @@
.actionIconGroup { .actionIconGroup {
background: var(--mantine-color-body); background: var(--mantine-color-body);
} }
.page-title .ProseMirror h1 {
font-size: 2.5rem;
font-weight: 700;
margin-top: 0;
margin-bottom: 0.75em;
}
@@ -244,6 +244,7 @@ export function TitleEditor({
} }
return ( return (
<div className="page-title">
<EditorContent <EditorContent
editor={titleEditor} editor={titleEditor}
onKeyDown={(event) => { onKeyDown={(event) => {
@@ -254,5 +255,6 @@ export function TitleEditor({
handleTitleKeyDown(event); handleTitleKeyDown(event);
}} }}
/> />
</div>
); );
} }