Skip to content

Commit

Permalink
Version 0.9.9
Browse files Browse the repository at this point in the history
  • Loading branch information
Sub6Resources committed May 18, 2019
1 parent 5dd1aea commit 3bb61b2
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 35 deletions.
6 changes: 5 additions & 1 deletion CHANGELOG.md
@@ -1,3 +1,7 @@
## [0.9.9] - May 17, 2019:

* Fixes extra padding issue ([#87](https://github.com/Sub6Resources/flutter_html/issues/87))

## [0.9.8] - May 14, 2019:

* Add support for `address` tag in `RichText` parser.
Expand All @@ -7,7 +11,7 @@
* Added onImageError callback
* Added custom textstyle and edgeinsets callback ([#72](https://github.com/Sub6Resources/flutter_html/pull/72))
* Update dependency versions ([#84](https://github.com/Sub6Resources/flutter_html/issues/84))
* Fixes #82 and #86
* Fixes [#82](https://github.com/Sub6Resources/flutter_html/issues/82) and [#86](https://github.com/Sub6Resources/flutter_html/issues/86)

## [0.9.6] - March 11, 2019:

Expand Down
2 changes: 1 addition & 1 deletion README.md
Expand Up @@ -9,7 +9,7 @@ A Flutter widget for rendering static html tags as Flutter widgets. (Will render
Add the following to your `pubspec.yaml` file:

dependencies:
flutter_html: ^0.9.8
flutter_html: ^0.9.9

## Currently Supported HTML Tags:
`a`, `abbr`, `acronym`, `address`, `article`, `aside`, `b`, `bdi`, `bdo`, `big`, `blockquote`, `body`, `br`, `caption`, `cite`, `code`, `data`, `dd`, `del`, `dfn`, `div`, `dl`, `dt`, `em`, `figcaption`, `figure`, `footer`, `h1`, `h2`, `h3`, `h4`, `h5`, `h6`, `header`, `hr`, `i`, `img`, `ins`, `kbd`, `li`, `main`, `mark`, `nav`, `noscript`, `ol`, `p`, `pre`, `q`, `rp`, `rt`, `ruby`, `s`, `samp`, `section`, `small`, `span`, `strike`, `strong`, `sub`, `sup`, `table`, `tbody`, `td`, `template`, `tfoot`, `th`, `thead`, `time`, `tr`, `tt`, `u`, `ul`, `var`
Expand Down
36 changes: 7 additions & 29 deletions lib/html_parser.dart
Expand Up @@ -755,11 +755,13 @@ class HtmlRichTextParser extends StatelessWidget {
));
}
BlockText blockText = BlockText(
margin: _customEdgeInsets ??
EdgeInsets.only(
top: 8.0,
bottom: 8.0,
left: parseContext.indentLevel * indentSize),
margin: node.localName != 'body'
? _customEdgeInsets ??
EdgeInsets.only(
top: 8.0,
bottom: 8.0,
left: parseContext.indentLevel * indentSize)
: EdgeInsets.zero,
padding: EdgeInsets.all(2.0),
decoration: decoration,
child: RichText(
Expand All @@ -784,30 +786,6 @@ class HtmlRichTextParser extends StatelessWidget {
}
}

// List<dynamic> _parseNodeList({
// @required List<dom.Node> nodeList,
// @required List<BlockText> rootWidgetList, // the widgetList accumulator
// int parentIndex, // the parent spans list accumulator
// int indentLevel = 0,
// int listCount = 0,
// String listChar = '•',
// String blockType, // blockType can be 'p', 'div', 'ul', 'ol', 'blockquote'
// bool condenseWhitespace = true,
// }) {
// return nodeList.map((node) {
// return _parseNode(
// node: node,
// rootWidgetList: rootWidgetList,
// parentIndex: parentIndex,
// indentLevel: indentLevel,
// listCount: listCount,
// listChar: listChar,
// blockType: blockType,
// condenseWhitespace: condenseWhitespace,
// );
// }).toList();
// }

Paint _getPaint(Color color) {
Paint paint = new Paint();
paint.color = color;
Expand Down
6 changes: 3 additions & 3 deletions pubspec.lock
Expand Up @@ -14,7 +14,7 @@ packages:
name: async
url: "https://pub.dartlang.org"
source: hosted
version: "2.2.0"
version: "2.1.0"
boolean_selector:
dependency: transitive
description:
Expand Down Expand Up @@ -101,7 +101,7 @@ packages:
name: quiver
url: "https://pub.dartlang.org"
source: hosted
version: "2.0.3"
version: "2.0.2"
sky_engine:
dependency: transitive
description: flutter
Expand Down Expand Up @@ -148,7 +148,7 @@ packages:
name: test_api
url: "https://pub.dartlang.org"
source: hosted
version: "0.2.5"
version: "0.2.4"
typed_data:
dependency: transitive
description:
Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
@@ -1,6 +1,6 @@
name: flutter_html
description: A Flutter widget for rendering static html tags as Flutter widgets. (Will render over 70 different html tags!)
version: 0.9.8
version: 0.9.9
author: Matthew Whitaker <sub6resources@gmail.com>
homepage: https://github.com/Sub6Resources/flutter_html

Expand Down

0 comments on commit 3bb61b2

Please sign in to comment.