Skip to content

Commit

Permalink
Merge pull request #441 from voxmedia/fix-hotkey-formats
Browse files Browse the repository at this point in the history
Alternative fix for #432 that also works with formats added via quill.addFormat()
  • Loading branch information
jhchen committed Aug 7, 2015
2 parents ad73e17 + 6ec2509 commit 47ee993
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/modules/keyboard.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ class Keyboard
)
_.each(['bold', 'italic', 'underline'], (format) =>
this.addHotkey(Keyboard.hotkeys[format.toUpperCase()], (range) =>
if (@quill.options.formats.indexOf(format) > -1)
if (@quill.editor.doc.formats[format])
this.toggleFormat(range, format)
return false
)
Expand Down

0 comments on commit 47ee993

Please sign in to comment.