ep_headings
Advanced tools
Comparing version 0.1.4 to 0.1.5
@@ -16,3 +16,4 @@ { | ||
"eejsBlock_editbarMenuLeft": "ep_headings/index", | ||
"collectContentPre": "ep_headings/static/js/shared" | ||
"collectContentPre": "ep_headings/static/js/shared", | ||
"collectContentPost": "ep_headings/static/js/shared" | ||
} | ||
@@ -19,0 +20,0 @@ } |
{ | ||
"description": "Adds heading support to Etherpad Lite.", | ||
"name": "ep_headings", | ||
"version": "0.1.4", | ||
"version": "0.1.5", | ||
"author": "fourplusone <info@fourplusone.de>", | ||
@@ -6,0 +6,0 @@ "contributors": [ |
@@ -10,7 +10,15 @@ var _ = require('ep_etherpad-lite/static/js/underscore'); | ||
var tagIndex = _.indexOf(tags, tname); | ||
if(tagIndex >= 0){ | ||
lineAttributes['heading'] = tags[tagIndex]; | ||
} | ||
else { | ||
}; | ||
var collectContentPost = function(hook, context){ | ||
var tname = context.tname; | ||
var state = context.state; | ||
var lineAttributes = state.lineAttributes | ||
var tagIndex = _.indexOf(tags, tname); | ||
if(tagIndex >= 0){ | ||
delete lineAttributes['heading']; | ||
@@ -21,1 +29,2 @@ } | ||
exports.collectContentPre = collectContentPre; | ||
exports.collectContentPost = collectContentPost; |
5929
141