summaryrefslogtreecommitdiff
path: root/doc/api
diff options
context:
space:
mode:
authorStefan <mu.stefan@googlemail.com>2015-01-25 22:08:40 +0100
committerStefan <mu.stefan@googlemail.com>2015-01-25 22:08:40 +0100
commit4c64b7a670c1db63ad42cfb1e5e78559e0fd1aeb (patch)
tree10e550296e99d5725412b39289e9a07ac92902c0 /doc/api
parentaca745ddf6a180e17c461bfb352281ee1f3acb1c (diff)
downloadetherpad-lite-4c64b7a670c1db63ad42cfb1e5e78559e0fd1aeb.zip
Revert 'asyncLineHTMLForExport' hook
Diffstat (limited to 'doc/api')
-rw-r--r--doc/api/hooks_server-side.md35
1 files changed, 1 insertions, 34 deletions
diff --git a/doc/api/hooks_server-side.md b/doc/api/hooks_server-side.md
index 75c3902b..c7e7a43a 100644
--- a/doc/api/hooks_server-side.md
+++ b/doc/api/hooks_server-side.md
@@ -245,7 +245,7 @@ Things in context:
2. attribLine - line attributes
3. text - line text
-This hook will allow a plug-in developer to re-write each line when exporting to HTML. Note that you problably don't want to use this plugin and will probably get better results from `asyncLineHTMLForExport`
+This hook will allow a plug-in developer to re-write each line when exporting to HTML.
Example:
```
@@ -271,39 +271,6 @@ function _analyzeLine(alineAttrs, apool) {
}
```
-## asyncLineHTMLForExport
-Called from: src/node/utils/ExportHtml.js
-
-Things in context:
-
-1. The context of the line
-2. lineContents - The HTML of the line
-3. Attribute pool
-4. Attribute line
-5. Line Text
-
-This hook will allow functions to be returned to modify the HTML.
-
-Example:
-
-```
-exports.asyncLineHTMLForExport = function (hook, context, cb) {
- cb(rewriteLine);
-}
-
-function rewriteLine(context){
- var lineContent = context.lineContent;
- sizes.forEach(function(size){
- size = size.replace("fs","");
- if(lineContent){
- lineContent = lineContent.replace("<fs"+size, "<span style='font-size:"+size+"px'");
- lineContent = lineContent.replace("</fs"+size, "</span");
- }
- });
- return lineContent;
-}
-```
-
## stylesForExport
Called from: src/node/utils/ExportHtml.js