-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
[lexical-playground] Feature: Highlight special strings with format #6860
[lexical-playground] Feature: Highlight special strings with format #6860
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
size-limit report 📦
|
This code fails the formatting checks, you can fix this with |
…itruscai/lexical into feat/highlight-special-strings
It looks like your e2e tests are failing:
Do you know how to run these locally? |
It looks like you need to run Note that to run the tests you will need the dev server running in another terminal (e.g. |
@etrepum sorry had wifi outage yesterday in area, since i made the special text feature into something you can switch on and off, how could i implement that in the test? do i need to set up a mock or something? |
…itruscai/lexical into feat/highlight-special-strings
It appears that this feature fails the collab test suite, which is run with |
That's not the problem. It keeps retrying because the result is incorrect, and then it times out. |
Were you running it with collab active? |
yes, should i disable collab in my tests? |
…itruscai/lexical into feat/highlight-special-strings # Conflicts: # packages/lexical-playground/__tests__/utils/index.mjs
Description
This PR introduces a SpecialTextNode and its corresponding plugin, enabling automatic recognition and highlighting of specific text patterns (e.g., [variableName]) in the editor. This feature enhances the editor's functionality by visually distinguishing variable-like text, as requested in Issue #6610.
Key changes:
SpecialTextNode: Recognizes specific string patterns and highlights them
SpecialTextPlugin: Processes any simple text string that starts with an opening bracket and closes with a closing bracket and applies the SpecialTextNode to remove brackets and highlight the string
Playground Integration: Added a toggle setting in the lexical-playground to enable or disable the SpecialTextPlugin for flexibility
Closes #6610
specialhighlight.mp4