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

formatting can result in removing text in slate (+other problems) #147

Open
djay opened this issue Aug 30, 2024 · 2 comments
Open

formatting can result in removing text in slate (+other problems) #147

djay opened this issue Aug 30, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@djay
Copy link
Member

djay commented Aug 30, 2024

Problem

The rich text editor needs to use transforms in slate package more directly so that the editor does the right thing when formatting text.

How to reproduce

  1. Selected the word Test.
  2. Clicked bold
  3. rest of the parapraph got removed

Other bugs

... TODO

Context

Image
Image

@djay djay added the bug Something isn't working label Aug 30, 2024
@djay
Copy link
Member Author

djay commented Sep 9, 2024

as discussed in the meeting. probably the best way to deal with it is use the slate package installed on the adminUI side. send over the selection and action, make a transformation and then send that updated state to both the slateblock on the admin side and back over the bridge as an update to be rerendered. Don't try to use the SlateBlock code directly.
Still keep the formatting UI on the frontend side.

@djay
Copy link
Member Author

djay commented Oct 16, 2024

So looking at the code

slate should in theory work without react but there doesn't seem to be much documentation on that

So haven't found an implementation without a framework.

Another option is to fake events to the react slate in the sidebar. doesn't seem like a good idea though

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant