-
Notifications
You must be signed in to change notification settings - Fork 23k
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
[FIX] web_editor: fix summernote text drop on firefox #42470
[FIX] web_editor: fix summernote text drop on firefox #42470
Conversation
@nle-odoo What do you think? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good, we normally try to avoid fix in external library but since it's an adapted backport of the current version, that might be alright
The e.preventDefault
is not in the linked version of summernote, isn't what they did:
enough to make it work?
it seems a little odd to prevent default on the whole document, I think it's possible to have another zone on the page where we would not want to prevent default.
robodoo delegate+
also I used to put around the code I changed in the library: /* ODOO: (start_modification */
... the code I'm adding or modifying
/* ODOO: end_modification) */ so when we update it it's a little easier to understand where we changed things, but I don't think we are going to update from this version. |
76a27e3
to
70e5e85
Compare
70e5e85
to
d593ed0
Compare
Indeed, it's better to do it only for the dropzone event! I added the comments, just in case. |
Issue - Have firefox - Go to any chatter - Open full editor - Write some "test" words with line breaks - Select one of your "test" words - Drag & drop it somewhere else in the editor Welcome on test.com! (redirected) Cause Summernote doesn't preventDefault on drop event, so firefox think we want to go to another URL. Solution Add the preventDefault manually. This reveals another issue which is solved by importing this PR's code summernote/summernote#3327 (with adaptation for our dinosaurus version) OPW-2158112
d593ed0
to
a4eae93
Compare
robodoo r+ |
Issue - Have firefox - Go to any chatter - Open full editor - Write some "test" words with line breaks - Select one of your "test" words - Drag & drop it somewhere else in the editor Welcome on test.com! (redirected) Cause Summernote doesn't preventDefault on drop event, so firefox think we want to go to another URL. Solution Add the preventDefault manually. This reveals another issue which is solved by importing this PR's code summernote/summernote#3327 (with adaptation for our dinosaurus version) OPW-2158112 closes #42470 Signed-off-by: Jason Van Malder <jvm-odoo@users.noreply.github.com>
This pull request has forward-port PRs awaiting action (not merged or closed): #42755 |
Issue
Cause
Solution
OPW-2158112
--
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr