react-md-editor icon indicating copy to clipboard operation
react-md-editor copied to clipboard

Text, cursor and selection not aligned

Open ajboni opened this issue 1 year ago • 5 comments

I get this behaviour in latest "@uiw/react-md-editor": "^3.20.7", seems similar to other cursor issues

image

Using electron 24 which is chromium based

ajboni avatar Apr 12 '23 02:04 ajboni

@ajboni Usually, this is caused by a conflict of styles.

You can reproduce your error using https://codesandbox.io and I can help you to have a look.

jaywcjlove avatar Apr 12 '23 05:04 jaywcjlove

Thanks, very difficult to reproduce in codesandbox... any hint on what style could be causing such behaviour?

ajboni avatar Apr 13 '23 00:04 ajboni

Hello, I encounter this problem too. Any idea on how to fix this please ?

Edit: @ajboni I just found the styles conflict. I had different font-size on my own textarea and the lib textarea font-size. Putting both textarea font-size the same fixed the problem.

Cheers !

podotki avatar Apr 13 '23 09:04 podotki

  • https://github.com/uiwjs/react-md-editor/issues/566#issuecomment-1684722412

jaywcjlove avatar Aug 19 '23 03:08 jaywcjlove

I think that is a font family problem

in my global css I added this 👇👇

.w-md-editor-text-pre,
.w-md-editor-text-input,
.w-md-editor-text > .w-md-editor-text-pre {
  font-family: inherit !important;
}

sito8943 avatar Sep 28 '23 15:09 sito8943