Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[PRO]: Emojis not returned correctly with getText #5934

Open
1 task done
ikoichi opened this issue Dec 13, 2024 · 0 comments
Open
1 task done

[PRO]: Emojis not returned correctly with getText #5934

ikoichi opened this issue Dec 13, 2024 · 0 comments
Labels
Category: Pro The issue or pull request is related to the pro packages of Tiptap. Type: Bug The issue or pullrequest is related to a bug

Comments

@ikoichi
Copy link

ikoichi commented Dec 13, 2024

Affected Packages

emoji

Version(s)

2.4.0

Description of the Bug

I added the emoji extension to my tiptap editor, with this configuration.

Emoji.configure({
      emojis: emojis,
      enableEmoticons: true,
      suggestion,
    }),

I type this emoji into the editor in the web browser: 1️⃣ (both using the macOS native emoji picker of the emoji picker itself)
I use editor.getText() to read the content.

                onBlur={(e) => {
                  const _text = e.editor.getText({ blockSeparator: "\n" });
                  console.log(">>> _text", _text);
                  onBlur(_text);
                }}

And this is what I get.
image

If I remove the Emoji extension, all works as expected, but my users will not have an emoji picker in the browser.

Browser Used

Chrome

Code Example (Preferred)

No response

Expected Behavior

The string returned by getText() should contain the emoji 1️⃣

Additional Context (Optional)

No response

Dependency Updates

  • Yes, I've updated all my dependencies.
@ikoichi ikoichi added Category: Pro The issue or pull request is related to the pro packages of Tiptap. Type: Bug The issue or pullrequest is related to a bug labels Dec 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Category: Pro The issue or pull request is related to the pro packages of Tiptap. Type: Bug The issue or pullrequest is related to a bug
Projects
None yet
Development

No branches or pull requests

1 participant