mirror of
https://github.com/purrgrammer/grimoire.git
synced 2026-04-10 15:36:53 +02:00
Fix cursor placement on mobile devices
- Made placeholder absolutely positioned to prevent it from affecting cursor - Added position: relative to .ProseMirror container - This ensures cursor appears at the start of input on mobile browsers The absolute positioning removes the placeholder from the normal layout flow, preventing mobile browsers from placing the cursor after the pseudo-element.
This commit is contained in:
@@ -283,6 +283,7 @@ body.animating-layout
|
||||
.ProseMirror {
|
||||
min-height: 1.25rem;
|
||||
line-height: 1.25rem;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.ProseMirror:focus {
|
||||
@@ -298,6 +299,9 @@ body.animating-layout
|
||||
content: attr(data-placeholder);
|
||||
color: hsl(var(--muted-foreground));
|
||||
pointer-events: none;
|
||||
position: absolute;
|
||||
left: 0;
|
||||
top: 0;
|
||||
}
|
||||
|
||||
/* Mention styles */
|
||||
|
||||
Reference in New Issue
Block a user