Skip to content

Convert custom emoji back to GFM when pasting

Simon Knox requested to merge psi-cp-custom into master

What does this MR do?

Correctly convert custom emojis with copying GFM. Fixes #335258 (closed)

Demo

before after
Screen_Recording_2021-10-13_at_1.28.58_pm Screen_Recording_2021-10-13_at_1.31.42_pm

Testing

  1. Enable custom_emoji feature flag
  2. Create a custom emoji using graphql. The following adds :iteration: to gitlab-org group:
mutation CreateCustomEmoji {
  createCustomEmoji(input: {groupPath: "gitlab-org", name: "iteration", url: "https://about.gitlab.com/images/all-remote/gitlab-value-tanukis_iteration.svg"}) {
    clientMutationId
    errors
  }
}
  1. Add custom emoji to a markdown comment
  2. Copy comment, paste to new comment
  3. See custom emoji, not a 300x300px SVG image
Edited by Simon Knox

Merge request reports