1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2024-11-23 18:17:20 +00:00

Add 'formattedtext' output type to Wikify widget

This commit is contained in:
Jermolene 2016-10-18 09:13:52 +01:00
parent 2f590a365e
commit d9f301f755
2 changed files with 9 additions and 4 deletions

View File

@ -71,6 +71,9 @@ WikifyWidget.prototype.getResult = function() {
case "text": case "text":
result = this.wikifyContainer.textContent; result = this.wikifyContainer.textContent;
break; break;
case "formattedtext":
result = this.wikifyContainer.formattedTextContent;
break;
case "html": case "html":
result = this.wikifyContainer.innerHTML; result = this.wikifyContainer.innerHTML;
break; break;

View File

@ -1,8 +1,9 @@
title: WikifyWidget
created: 20160321144949700
modified: 20160321144949700
tags: Widgets
caption: wikify caption: wikify
created: 20160321144949700
modified: 20161017122117062
tags: Widgets
title: WikifyWidget
type: text/vnd.tiddlywiki
! Introduction ! Introduction
@ -23,6 +24,7 @@ The available output types are:
|!Keyword |!Description | |!Keyword |!Description |
|text |Return the plain text of the rendered output (ie HTML tags are omitted) | |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 | |html |Return the rendered HTML of the output |
|parsetree |Return a formatted JSON representation of the parse tree | |parsetree |Return a formatted JSON representation of the parse tree |
|widgettree |Return a formatted JSON representation of the widget tree | |widgettree |Return a formatted JSON representation of the widget tree |