Browse Source

fix: Fixed alignement of rich text nodes

pull/7046/head
Muhammed Mustafa 1 year ago
parent
commit
0dab884ea9
  1. 14
      packages/nc-gui/components/cell/RichText.vue
  2. 2
      packages/nc-gui/components/cell/TextArea.vue

14
packages/nc-gui/components/cell/RichText.vue

@ -160,7 +160,7 @@ const focusEditorEnd = () => {
'flex flex-col flex-grow': props.fullMode, 'flex flex-col flex-grow': props.fullMode,
}" }"
> >
<div v-if="props.showMenu" class="absolute top-1 z-1000 right-3"> <div v-if="props.showMenu" class="absolute top-1 right-3">
<CellRichTextSelectedBubbleMenu v-if="editor" :editor="editor" embed-mode /> <CellRichTextSelectedBubbleMenu v-if="editor" :editor="editor" embed-mode />
</div> </div>
<CellRichTextSelectedBubbleMenuPopup v-if="editor" :editor="editor" /> <CellRichTextSelectedBubbleMenuPopup v-if="editor" :editor="editor" />
@ -185,6 +185,10 @@ const focusEditorEnd = () => {
.nc-textarea-rich { .nc-textarea-rich {
.ProseMirror { .ProseMirror {
@apply pt-1; @apply pt-1;
> * {
@apply ml-1;
}
} }
.ProseMirror-focused { .ProseMirror-focused {
// remove all border // remove all border
@ -196,14 +200,14 @@ const focusEditorEnd = () => {
} }
ul { ul {
@apply ml-4;
li { li {
@apply ml-4;
list-style-type: disc; list-style-type: disc;
} }
} }
ol { ol {
@apply -ml-6; @apply -ml-6 !pl-4;
li { li {
list-style-type: decimal; list-style-type: decimal;
} }
@ -215,9 +219,9 @@ const focusEditorEnd = () => {
} }
ul[data-type='taskList'] { ul[data-type='taskList'] {
@apply ml-1; @apply;
li { li {
@apply flex flex-row gap-x-2; @apply !ml-0 flex flex-row gap-x-2;
list-style-type: none; list-style-type: none;
input { input {

2
packages/nc-gui/components/cell/TextArea.vue

@ -200,7 +200,7 @@ const isRichMode = computed(() => {
<LazyCellRichText <LazyCellRichText
v-else-if="isVisible" v-else-if="isVisible"
v-model:value="vModel" v-model:value="vModel"
class="ml-2 mt-2 nc-scrollbar-md" class="ml-2 nc-scrollbar-md"
:style="{ :style="{
'max-height': 'calc(min(60vh, 100rem))', 'max-height': 'calc(min(60vh, 100rem))',
}" }"

Loading…
Cancel
Save