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

Adding another option strikethrough Enhancement #132

Open
ismaelw opened this issue Jan 28, 2016 · 0 comments
Open

Adding another option strikethrough Enhancement #132

ismaelw opened this issue Jan 28, 2016 · 0 comments

Comments

@ismaelw
Copy link

ismaelw commented Jan 28, 2016

I needed another formatting option "strikethrough". I just added it myself.

  • For this I added the keycode for the letter "L" to enable the shortcut cmd+L
    76: "strikethrough",
  • Next I edited the "updateState" event
    strike: "strikethrough",
  • And also added "strike" to the checkForFormatting function
    var n = ["b", "i", "u", "strike", "h1", "h2", "ol", "ul", "li", "a"];
  • And last but not least I added the "strikethrough" command
    strikethrough: function(e) { e.preventDefault(), t.execCommand("strikeThrough", !1), u.update.call(this), m.change.call(this) },
  • For the CSS part I added the following line
    .jquery-notebook.bubble button.strikethrough:after{content:"\f0cc"}

This is it. Maybe you can implement this into your next version. Thanks for this awesome tool!

@ismaelw ismaelw changed the title Adding another option StrikeThrough Enhancement Adding another option strikethrough Enhancement Jan 28, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant