From 5aaa9bff9aedbc2331b19a5b670ef11c2f3928f6 Mon Sep 17 00:00:00 2001 From: Eric Kok Date: Thu, 1 Apr 2021 23:33:55 +0200 Subject: [PATCH 01/10] Prepare 2.0.0 non-preview release --- CHANGELOG.md | 6 ++++++ pubspec.yaml | 4 ++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index fcaeddd16c..ebf2670942 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,9 @@ +## [2.0.0] - April 1, 2021: +* Support basic MathML +* Supply full context tree to custom render +* Fixed lists not rendering correctly +* Fixes for colspans in tables + ## [2.0.0-nullsafety.0] - March 5, 2021: * Nullsafety support * Official Flutter Web support diff --git a/pubspec.yaml b/pubspec.yaml index 93f9779472..f8afcf2575 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,6 +1,6 @@ name: flutter_html description: A Flutter widget rendering static HTML and CSS as Flutter widgets. -version: 2.0.0-nullsafety.0 +version: 2.0.0 homepage: https://github.com/Sub6Resources/flutter_html environment: @@ -16,7 +16,7 @@ dependencies: css_colors: ^1.1.0 # Plugins for rendering the tag. - flutter_layout_grid: ^1.0.0-nullsafety.6 + flutter_layout_grid: ^1.0.1 # Plugins for rendering the
+ + + + +
Monthly savings
January February March April May June July August September October November December
\$100 \$50 \$80 \$60 \$90 \$140 \$110 \$80 \$90 \$60 \$40 \$70
\90 \$60 \$80 \$80 \$100 \$160 \$150 \$110 \$100 \$60 \$30 \$80
+ """, + customRender: { + "table": (context, child) { + return SingleChildScrollView( + scrollDirection: Axis.horizontal, + child: (context.tree as TableLayoutElement).toWidget(context), + ); + } + }, +); +``` + +3. Complex example - rendering an `iframe` differently based on whether it is an embedded youtube video or some other embedded content.
View code From b4733074d69e1b0e5cada786098c813051a64c98 Mon Sep 17 00:00:00 2001 From: Eric Kok Date: Wed, 21 Apr 2021 09:44:37 +0200 Subject: [PATCH 04/10] Update changelog with tagsList param --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index ebf2670942..8d3b14236d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,7 @@ ## [2.0.0] - April 1, 2021: * Support basic MathML * Supply full context tree to custom render +* Include or exclude specific tags via `tagsList` parameter * Fixed lists not rendering correctly * Fixes for colspans in tables From 5eacbf6187d6541450a680fb559b070de4dcd906 Mon Sep 17 00:00:00 2001 From: Eric Kok Date: Fri, 23 Apr 2021 10:44:01 +0200 Subject: [PATCH 05/10] Bump flutter_svg to stable nullsafety relesae --- example/ios/Podfile.lock | 4 ++-- pubspec.yaml | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/example/ios/Podfile.lock b/example/ios/Podfile.lock index 7503100e5b..e3543a279d 100644 --- a/example/ios/Podfile.lock +++ b/example/ios/Podfile.lock @@ -26,8 +26,8 @@ EXTERNAL SOURCES: SPEC CHECKSUMS: Flutter: 434fef37c0980e73bb6479ef766c45957d4b510c video_player: 9cc823b1d9da7e8427ee591e8438bfbcde500e6e - wakelock: bfc7955c418d0db797614075aabbc58a39ab5107 - webview_flutter: d2b4d6c66968ad042ad94cbb791f5b72b4678a96 + wakelock: b0843b2479edbf6504d8d262c2959446f35373aa + webview_flutter: 9f491a9b5a66f2573946a389b2677987b0ff8c0b PODFILE CHECKSUM: 8e679eca47255a8ca8067c4c67aab20e64cb974d diff --git a/pubspec.yaml b/pubspec.yaml index f6cc27b2c9..eba6ea61dd 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -29,10 +29,10 @@ dependencies: chewie_audio: ^1.2.0 # Plugins for rendering the tag. - flutter_svg: ^0.21.0-nullsafety.0 + flutter_svg: ^0.21.0+1 # Plugin for rendering MathML - flutter_math_fork: ^0.3.0+1 + flutter_math_fork: ^0.3.0+2 flutter: sdk: flutter From 0ed979c25e15dd5923b873393fa48d54c1c44e52 Mon Sep 17 00:00:00 2001 From: Eric Kok Date: Sat, 24 Apr 2021 23:23:35 +0200 Subject: [PATCH 06/10] Update pubspec.yaml with latest flutter_svg Co-authored-by: Dennis Kugelmann --- pubspec.yaml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pubspec.yaml b/pubspec.yaml index eba6ea61dd..28744c0416 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -32,7 +32,7 @@ dependencies: flutter_svg: ^0.21.0+1 # Plugin for rendering MathML - flutter_math_fork: ^0.3.0+2 + flutter_math_fork: ^0.3.0+3 flutter: sdk: flutter @@ -42,4 +42,3 @@ dev_dependencies: sdk: flutter flutter: - From ba391f7dbbe5b8314172b0f634bebe031b148f35 Mon Sep 17 00:00:00 2001 From: Eric Kok Date: Thu, 29 Apr 2021 09:22:15 +0200 Subject: [PATCH 07/10] Updated CHANGELOG with latest changes --- CHANGELOG.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8d3b14236d..750c63f5cd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,12 @@ * Include or exclude specific tags via `tagsList` parameter * Fixed lists not rendering correctly * Fixes for colspans in tables +* Fixed various exceptions when using inline styles +* Fixed text decoration not cascading between parent and child +* [BREAKING] support whitelisting tags + * See the README for details on how to migrate `blacklistedElements` (deprecated) to `tagsList` +* Fixed `failed assertion` error when tap-scrolling on any link +* Updated dependencies ## [2.0.0-nullsafety.0] - March 5, 2021: * Nullsafety support From ad75c59351b56a8576776d33b0403773d2cdf5ec Mon Sep 17 00:00:00 2001 From: Eric Kok Date: Thu, 29 Apr 2021 11:04:36 +0200 Subject: [PATCH 08/10] Update changelog with inner links support --- CHANGELOG.md | 1 + README.md | 2 ++ 2 files changed, 3 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 750c63f5cd..1a19b622e1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,6 @@ ## [2.0.0] - April 1, 2021: * Support basic MathML +* Support inner links * Supply full context tree to custom render * Include or exclude specific tags via `tagsList` parameter * Fixed lists not rendering correctly diff --git a/README.md b/README.md index ca1cfade09..1d1a2d849f 100644 --- a/README.md +++ b/README.md @@ -242,6 +242,8 @@ Widget html = Html( ); ``` +Inner links (such as `Back to the top` will work out of the box by scrolling the viewport, as long as your `Html` widget is wrapped in a scroll container such as a `SingleChildScrollView`. + ### customRender: A powerful API that allows you to customize everything when rendering a specific HTML tag. This means you can change the default behaviour or add support for HTML elements that aren't supported natively. You can also make up your own custom tags in your HTML! From 0c6db96221cc005f866ffc4c17c2d4e0fd04220d Mon Sep 17 00:00:00 2001 From: Eric Kok Date: Thu, 29 Apr 2021 11:08:25 +0200 Subject: [PATCH 09/10] Prepare 2.0.0-nullsafety.1 --- CHANGELOG.md | 2 +- pubspec.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 1a19b622e1..f1d130edcd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,4 @@ -## [2.0.0] - April 1, 2021: +## [2.0.0-nullsafety.1] - April 29, 2021: * Support basic MathML * Support inner links * Supply full context tree to custom render diff --git a/pubspec.yaml b/pubspec.yaml index 6567c3937e..04b7d5a03b 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,6 +1,6 @@ name: flutter_html description: A Flutter widget rendering static HTML and CSS as Flutter widgets. -version: 2.0.0 +version: 2.0.0-nullsafety.1 homepage: https://github.com/Sub6Resources/flutter_html environment: From 3b72002527457f86ead557ce6e0a002c7e8ed7c0 Mon Sep 17 00:00:00 2001 From: Eric Kok Date: Thu, 29 Apr 2021 11:12:35 +0200 Subject: [PATCH 10/10] Mention 2.0.0 in README --- CHANGELOG.md | 3 +++ README.md | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f1d130edcd..9195d6ea65 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,6 @@ +## [2.0.0] - April 29, 2021: +* Stable release with all 2.0.0-nullsafety.X changes + ## [2.0.0-nullsafety.1] - April 29, 2021: * Support basic MathML * Support inner links diff --git a/README.md b/README.md index 1d1a2d849f..d464ba287b 100644 --- a/README.md +++ b/README.md @@ -96,7 +96,7 @@ A Flutter widget for rendering HTML and CSS as Flutter widgets. Add the following to your `pubspec.yaml` file: dependencies: - flutter_html: ^1.3.0 + flutter_html: ^2.0.0 ## Currently Supported HTML Tags: | | | | | | | | | | | |