Skip to content

Commit

Permalink
Add 'formattedtext' output type to Wikify widget
Browse files Browse the repository at this point in the history
  • Loading branch information
Jermolene committed Oct 18, 2016
1 parent 2f590a3 commit d9f301f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
3 changes: 3 additions & 0 deletions core/modules/widgets/wikify.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,9 @@ WikifyWidget.prototype.getResult = function() {
case "text":
result = this.wikifyContainer.textContent;
break;
case "formattedtext":
result = this.wikifyContainer.formattedTextContent;
break;
case "html":
result = this.wikifyContainer.innerHTML;
break;
Expand Down
8 changes: 5 additions & 3 deletions editions/tw5.com/tiddlers/widgets/WikifyWidget.tid
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
title: WikifyWidget
caption: wikify
created: 20160321144949700
modified: 20160321144949700
modified: 20161017122117062
tags: Widgets
caption: wikify
title: WikifyWidget
type: text/vnd.tiddlywiki

! Introduction

Expand All @@ -23,6 +24,7 @@ The available output types are:

|!Keyword |!Description |
|text |Return the plain text of the rendered output (ie HTML tags are omitted) |
|formattedtext |Return the plain text with simple text formatting of the rendered output (ie HTML tags are omitted) |
|html |Return the rendered HTML of the output |
|parsetree |Return a formatted JSON representation of the parse tree |
|widgettree |Return a formatted JSON representation of the widget tree |

0 comments on commit d9f301f

Please sign in to comment.