chore: fix super block cursor

This commit is contained in:
Aman Harwara
2023-12-05 13:54:33 +05:30
parent a1f0ec3afd
commit 39f49d3e8e
2 changed files with 21 additions and 0 deletions

View File

@@ -1,6 +1,7 @@
import type { EditorThemeClasses } from 'lexical'
const BlocksEditorTheme: EditorThemeClasses = {
blockCursor: 'Lexical__blockCursor',
characterLimit: 'Lexical__characterLimit',
code: 'Lexical__code',
codeHighlight: {

View File

@@ -246,3 +246,23 @@
.Lexical__embedBlockFocus {
outline: 2px solid var(--sn-stylekit-info-color);
}
.Lexical__blockCursor {
display: block;
pointer-events: none;
position: absolute;
}
.Lexical__blockCursor:after {
content: '';
display: block;
position: absolute;
top: -2px;
width: 20px;
border-top: 1px solid var(--sn-stylekit-editor-foreground-color);
animation: CursorBlink 1.1s steps(2, start) infinite;
}
@keyframes CursorBlink {
to {
visibility: hidden;
}
}