fix(richtext-lexical): editor placeholder had incorrect padding set for small viewports (#10531)
Before:  After: 
This commit is contained in:
@@ -12,7 +12,8 @@ $lexical-contenteditable-bottom-padding: 8px;
|
||||
outline: 0;
|
||||
padding-top: $lexical-contenteditable-top-padding;
|
||||
padding-bottom: $lexical-contenteditable-bottom-padding;
|
||||
//min-height: base(10);
|
||||
padding-left: 0;
|
||||
padding-right: 0;
|
||||
|
||||
&:focus-visible {
|
||||
outline: none !important;
|
||||
@@ -24,32 +25,23 @@ $lexical-contenteditable-bottom-padding: 8px;
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 768px) {
|
||||
.ContentEditable__root {
|
||||
padding-left: 0;
|
||||
padding-right: 0;
|
||||
.rich-text-lexical--show-gutter
|
||||
> .rich-text-lexical__wrap
|
||||
> .editor-container
|
||||
> .editor-scroller
|
||||
> .editor {
|
||||
> .ContentEditable__root {
|
||||
padding-left: 3rem;
|
||||
}
|
||||
}
|
||||
|
||||
@media (min-width: 769px) {
|
||||
.rich-text-lexical--show-gutter
|
||||
> .rich-text-lexical__wrap
|
||||
> .editor-container
|
||||
> .editor-scroller
|
||||
> .editor {
|
||||
> .ContentEditable__root {
|
||||
padding-left: 3rem;
|
||||
}
|
||||
> .ContentEditable__root::before {
|
||||
content: ' ';
|
||||
position: absolute;
|
||||
top: $lexical-contenteditable-top-padding;
|
||||
left: 0;
|
||||
height: calc(
|
||||
100% - #{$lexical-contenteditable-top-padding} - #{$lexical-contenteditable-bottom-padding}
|
||||
);
|
||||
border-left: 1px solid var(--theme-elevation-100);
|
||||
}
|
||||
> .ContentEditable__root::before {
|
||||
content: ' ';
|
||||
position: absolute;
|
||||
top: $lexical-contenteditable-top-padding;
|
||||
left: 0;
|
||||
height: calc(
|
||||
100% - #{$lexical-contenteditable-top-padding} - #{$lexical-contenteditable-bottom-padding}
|
||||
);
|
||||
border-left: 1px solid var(--theme-elevation-100);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user