ef2-digital / strapi-plugin-bold-title-editor

7 stars 2 forks source link

Newline character inserted between each letter #6

Open Norbz opened 1 year ago

Norbz commented 1 year ago

Hi there,

Thanks for your plugin. This is a really simple but useful idea :)

I'm getting a weird behavior, every new letter goes to a new line : Capture d’écran 2023-07-28 à 11 35 33

Actually, every letter have a space after it, then a newline

In the API response, I'm getting \n characters between each letter as well : Capture d’écran 2023-07-28 à 11 49 25

You can manually remove every space and get the correct behavior

Im using strapi v4.11.7 plugin version is v1.0.8 Happens on Firefox v90 up to v115, both mac and windows (tested without any firefox extensions)

the custom field is being used in a component, in a dynamic zone, or directly in a content-type, required or not.

Let me know if you need more info :)

robclancy commented 1 year ago

I just spent a long time thinking there was a react issue with this when it turns out it was this plugin. I had to add title = title.replace(/\u00A0/g, ' '); to work around it.

Norbz commented 2 months ago

Hi

Any news on this ? Seems to be a pretty silly bug, completely banning the possibility to use it for projects that will be managed by clients...