Skip to content

Commit

Permalink
5.4.0
Browse files Browse the repository at this point in the history
  • Loading branch information
nmielnik committed Jul 16, 2015
1 parent a61521c commit ebfacb7
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 10 deletions.
5 changes: 5 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
5.4.0 / 2015-07-16
==================
* Add support for including 'alt' key in keyboard-commands


5.3.0 / 2015-07-07
==================
* Fix issue with disabling image drag & drop via imageDragging option
Expand Down
18 changes: 12 additions & 6 deletions dist/js/medium-editor.js
Original file line number Diff line number Diff line change
Expand Up @@ -3861,25 +3861,29 @@ var KeyboardCommands;
* key [String] (keyboard character that triggers this command)
* meta [boolean] (whether the ctrl/meta key has to be active or inactive)
* shift [boolean] (whether the shift key has to be active or inactive)
* alt [boolean] (whether the alt key has to be active or inactive)
*/
commands: [
{
command: 'bold',
key: 'B',
meta: true,
shift: false
shift: false,
alt: false
},
{
command: 'italic',
key: 'I',
meta: true,
shift: false
shift: false,
alt: false
},
{
command: 'underline',
key: 'U',
meta: true,
shift: false
shift: false,
alt: false
}
],

Expand All @@ -3904,11 +3908,13 @@ var KeyboardCommands;
}

var isMeta = Util.isMetaCtrlKey(event),
isShift = !!event.shiftKey;
isShift = !!event.shiftKey,
isAlt = !!event.altKey;

this.keys[keyCode].forEach(function (data) {
if (data.meta === isMeta &&
data.shift === isShift) {
data.shift === isShift &&
data.alt === isAlt) {
event.preventDefault();
event.stopPropagation();

Expand Down Expand Up @@ -6202,7 +6208,7 @@ MediumEditor.parseVersionString = function (release) {

MediumEditor.version = MediumEditor.parseVersionString.call(this, ({
// grunt-bump looks for this:
'version': '5.3.0'
'version': '5.4.0'
}).version);

return MediumEditor;
Expand Down
5 changes: 3 additions & 2 deletions dist/js/medium-editor.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "medium-editor",
"version": "5.3.0",
"version": "5.4.0",
"author": "Davi Ferreira <hi@daviferreira.com>",
"contributors": [
{
Expand Down
2 changes: 1 addition & 1 deletion src/js/version.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,5 @@ MediumEditor.parseVersionString = function (release) {

MediumEditor.version = MediumEditor.parseVersionString.call(this, ({
// grunt-bump looks for this:
'version': '5.3.0'
'version': '5.4.0'
}).version);

0 comments on commit ebfacb7

Please sign in to comment.