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

Problem with shortcuts in polish language #330

Closed
azug opened this issue Mar 2, 2017 · 4 comments
Closed

Problem with shortcuts in polish language #330

azug opened this issue Mar 2, 2017 · 4 comments

Comments

@azug
Copy link

azug commented Mar 2, 2017

For Feature Requests

Desired Feature: remove shortcut during hold right alt + s.

For Bug Reports

  • BookStack Version: BookStack v0.15.0
  • PHP Version: PHP 5.6.30-0+deb8u1
  • MySQL Version: Ver 14.14 Distrib 5.6.30
Expected Behavior

When hold right alt and enter "s" do nothing

Actual Behavior

When hold right alt and enter "s" in polish language you can enter "ś" letter but when I try to insert "ś" in text area document bookstack "save draft". It happen only when editing document.
Look at below screenshot:
http://screenshot.sh/n9nZrlvJNsyz2

Is it possible to turn off all shortcuts ?

Regards,
Arkadiusz Zug

@arkadiyasuratov
Copy link

Can confirm. The issue is still present in the current beta v0.18. Would be nice to be able to remap the key in the settings panel or just be able to turn off this particular shortcut.

Qucik and ugly way to solve it, is by editing the file common.js in public/js/ directory.

Just find and remove this line of code:
n.on("keydown",function(e){83===e.keyCode&&(navigator.platform.match("Mac")?e.metaKey:e.ctrlKey)&&(e.preventDefault(),t.$emit("save-draft",e))}),

Here's the file from version v0.18 without the above line of code.

Or you can remap the S key code 83 to any other key.
You can lookup a keycode on this website for example: http://keycode.info/

Just a temporary solution, but hopefully it will help someone like me until it get addressed in the future release.

@AbijeetP
Copy link
Contributor

@ssddanbrown - Can we add a flag in the user profile to disable shortcuts?

@ssddanbrown ssddanbrown added this to the BookStack Beta v0.18.1 milestone Sep 15, 2017
@ssddanbrown
Copy link
Member

@AbijeetP I'd prefer not to have an additional setting if not required.

I think the base issue here is that event.ctrlKey = true even when ctrlKey is not pressed but AltGr is. Just need to add a check that altkey is not also pressed I think.

Marked for next bugfix release.

@ssddanbrown
Copy link
Member

Tested and found to be fixed in current master branch. Will be release as part of v0.18.2 (Hopefully today sometime).

Will close for now but please let me know if any issues are experienced upgrading to v0.18.2 once it's released.

Thanks for reporting.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

4 participants