Skip to content

Commit

Permalink
add unlink action
Browse files Browse the repository at this point in the history
  • Loading branch information
salkar committed Jun 1, 2014
1 parent 18eeab1 commit aba7c6f
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion morrigan-jquery-editor.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ $.widget( "morrigan.morrigan_editor", {
['img', 'video'],
['alignLeft', 'alignCenter', 'alignRight'],
['orderedList', 'unorderedList'],
['link']
['link', 'unLink']
]
],
popup: {
Expand Down Expand Up @@ -361,6 +361,18 @@ $.widget( "morrigan.morrigan_editor", {
this.changeActiveIcon(editor._window.document.queryCommandState('strikethrough'));
}
},
unLink: {
name: 'unLink',
view: {
title: 'Unlink',
activeBackground: '#aaa',
inactiveBackground: '#eee',
classes: 'fa fa-unlink'
},
onClickHandler: function (editor, action) {
editor._window.document.execCommand('Unlink', false, null);
}
},
link: {
name: 'link',
view: {
Expand Down

0 comments on commit aba7c6f

Please sign in to comment.