Hacktoberfest 2026 : les issues que les mainteneurs ont marquées pour octobre, ouvertes et accessibles aux débutants. Parcourir les issues Hacktoberfest

Rich text editor can generate potentially invalid commonmark

Ouverte
#59 0 commentaires 0 réactions 1 personne assignée Voir sur GitHub

Les mainteneurs répondent en général sous 1 jour

@tmcentee y travaille déjà.

Depuis le 11/7/2022.

  • #161 par @tmcentee — fermée sans fusion

Évaluation

Cette issue n'a pas encore été évaluée.

Description

bug commonmark

Reported on Meta.SE

Describe the bug

Overlapping bold/italic formatting leads to incorrect formatting when toggling to Markdown mode.

  1. In rich text mode, write some text.
    • this is bold, now italic, and now?!
  2. Select part of the text.
  3. Make the selection italic.
    • this is bold, now italic, and now?!
  4. Select some overlapping text.
  5. Make the selection bold.
    • this is bold, now italic, and now?!

(Now bold and italic formatting is correctly applied to overlapping portions of the text.)

When switching to Markdown, the formatting is screwed up because Markdown doesn’t support overlapping formatting in this way: adjacent */** is ambiguous at the best of times, but Markdown wouldn’t support this even when using _ to format italics.

Here’s what the editor generates:

**this is bold, *now italic****, and now?!*

… but as mentioned, even the following isn’t really supported by Markdown as far as I’m aware (it certainly isn’t on this site):

**this is bold, _now italic**, and now?!_
Langage dominant
TypeScript
Étoiles
441
Forks
61
Merge moyen
20 h 35 min
PR mergées (30 j)
18

Préparer son environnement

Par où commencer

  1. Lisez l'issue en entier, puis le guide de contribution du projet.
  2. Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
  3. Forkez le dépôt et travaillez sur une branche.
  4. Ouvrez une pull request qui référence le numéro de l'issue.

Autres issues de StackExchange/Stacks-Editor

Toutes les issues de StackExchange/Stacks-Editor

Issues similaires

Plus d'issues TypeScript

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.