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

Not all Codemirror shortcuts are working. #40595

Closed
bmankowski opened this issue May 15, 2023 · 6 comments
Closed

Not all Codemirror shortcuts are working. #40595

bmankowski opened this issue May 15, 2023 · 6 comments

Comments

@bmankowski
Copy link

Steps to reproduce the issue

Switch editor to Codemirror in global configuration.
During editing in Codemirror press "Ctrl+/" to comment a line or block.

Expected result

Line/block should be commented.

Actual result

Nothing happens.

System information (as much as possible)

Tried on freshly installed joomla 4 instalation, and asked on Joomla forum to check the scenario:
https://forum.joomla.org/viewtopic.php?f=814&t=1001653
and the other person had the same result.

Additional comments

@brianteeman
Copy link
Contributor

Why do you expect that behaviour?
Can you replicate it on a codemirror demo from the codemirror.net site?

@bmankowski
Copy link
Author

@brianteeman I expect this behavior because in https://codemirror.net/docs/ref/#commands "ctrl+/" is stated as "Ctrl-/ (Cmd-/ on macOS): toggleComment." Tried it in Joomla4 and as it doesn't work I filed this tikcet. Could you check if it works for you?


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/40595.

@bmankowski
Copy link
Author

On https://codemirror.net/ it works normally.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/40595.

@brianteeman
Copy link
Contributor

The links you shared are for codemirror v6. Joomla is currently using v5.
I checked the demos for v5 and unless I am missing something it is not a feature of v5
https://codemirror.net/5/demo/fullscreen.html

@bmankowski
Copy link
Author

In https://codemirror.net/5/doc/manual.html#commands it mention it's possible to use comment/comment.js
And in fact it's already in /media/vendor/codemirror/addon/comment
I just don't have a knowledge to bind it to a key.
Do you think it's worth to make this change, or do you think it's better to just wait for next version of codemirror to be introduced to Joomla v4?


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/40595.

@Fedik
Copy link
Member

Fedik commented Aug 21, 2023

It is working in Joomla 5 with Codemirror 6 #41070

@Fedik Fedik closed this as completed Aug 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants