Skip to content

Commit aa4dde1

Browse files
committed
Merge remote-tracking branch 'origin/master' into feature/modularization
# Conflicts: # README.md # example/lib/main.dart # lib/flutter_html.dart # lib/html_parser.dart # lib/image_render.dart # lib/src/html_elements.dart # lib/src/layout_element.dart # lib/src/replaced_element.dart # lib/src/utils.dart # lib/src/widgets/iframe_mobile.dart # lib/src/widgets/iframe_unsupported.dart # lib/src/widgets/iframe_web.dart # pubspec.yaml # test/html_parser_test.dart
2 parents 63cff05 + 2f3acc0 commit aa4dde1

22 files changed

+1198
-475
lines changed

CHANGELOG.md

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,66 @@
1+
## [2.2.1] - December 8, 2021:
2+
* Allow styling on ruby tags
3+
* Allow width/height/alignment styling on table/tr/td tags
4+
* Prevent images causing rebuilding and leaking memory
5+
* Fixes display of list items on iOS with font weights below 400
6+
* Prevent crash on negative margins or paddings
7+
8+
## [2.2.0] - November 29, 2021:
9+
* Explicitly declare multiplatform support
10+
* Extended and fixed list-style (marker) support
11+
* Basic support for height/width css properties
12+
* Support changing scroll physics of SelectableText.rich
13+
* Support text transform css property
14+
* Bumped minimum flutter_math_fork version for Flutter 2.5 compatibility
15+
* Fix styling of iframes
16+
* Fix nested font tag application
17+
* Fix whitespace rendering between list items
18+
* Prevent crash on empty <table> tag and tables with both colspan/rowspan
19+
* Prevent crash on use of negative margins in css
20+
21+
## [2.1.5] - October 7, 2021:
22+
* Ignore unsupported custom style selectors when using fromCss
23+
* Fix SVG tag usage inside tables
24+
* Properly fix regression in usage of line breaks
25+
26+
## [2.1.4] - October 3, 2021:
27+
* Fix regression in usage of line breaks in body being stripped
28+
29+
## [2.1.3] - October 1, 2021:
30+
* Update minimum versions of dependencies for Flutter 2.5 compatibility
31+
* Extended and fixed support for css shadow
32+
* Fix block tags with explicit whitespace from being stripped
33+
34+
## [2.1.2] - September 2, 2021:
35+
* Allow setting selectionControls with SelectableHtml
36+
* Fix onLinkTap not working with SelectableHtml
37+
* Don't crash when parsing unsupported :hover
38+
* Prevent endless loading when using animated images
39+
40+
## [2.1.1] - July 28, 2021:
41+
* Stable release with all 2.1.1-preview.X changes
42+
43+
## [2.1.1-preview.0] - July 27, 2021:
44+
* Improves hr tag support
45+
* Fixes a leading whitespace issue
46+
* Fixes some crashes with CSS parsing
47+
48+
## [2.1.0] - June 3, 2021:
49+
* SelectableHtml widget (supporting a subset of tags) which allow text selection
50+
* Fixed shrinkWrap to actually shrink the horizontal space
51+
* Support style tags to apply styling from inline css
52+
* Support applying styles from Flutter themes
53+
* Mouse hover on links when using Flutter Web
54+
* Allow custom anchor link tap implementations
55+
* Support additional list styling options
56+
* Fix several minor whitespace issues in text flow
57+
* Fixed specific colspan/rowspan usages in tables
58+
* Fixed whitespace issues around images
59+
* Swallow duplicate ids to prevent crashing the widget
60+
* Fixes crashing tap detection when using both link and image taps
61+
* Updates external dependencies
62+
* Raised minimum Flutter version to 2.2.0
63+
164
## [2.0.0] - April 29, 2021:
265
* Stable release with all 2.0.0-nullsafety.X changes
366

README.md

Lines changed: 45 additions & 202 deletions
Large diffs are not rendered by default.

example/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -158,6 +158,7 @@ const htmlData = """
158158
body: SingleChildScrollView(
159159
child: Html(
160160
data: htmlData,
161+
tagsList: Html.tags..addAll(["flutter"]),
161162
//Optional parameters:
162163
style: {
163164
"html": Style(

example/ios/Flutter/AppFrameworkInfo.plist

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,6 @@
2121
<key>CFBundleVersion</key>
2222
<string>1.0</string>
2323
<key>MinimumOSVersion</key>
24-
<string>8.0</string>
24+
<string>9.0</string>
2525
</dict>
2626
</plist>

example/ios/Podfile.lock

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,11 @@ EXTERNAL SOURCES:
2424
:path: ".symlinks/plugins/webview_flutter/ios"
2525

2626
SPEC CHECKSUMS:
27-
Flutter: 434fef37c0980e73bb6479ef766c45957d4b510c
27+
Flutter: 50d75fe2f02b26cc09d224853bb45737f8b3214a
2828
video_player: 9cc823b1d9da7e8427ee591e8438bfbcde500e6e
29-
wakelock: b0843b2479edbf6504d8d262c2959446f35373aa
29+
wakelock: d0fc7c864128eac40eba1617cb5264d9c940b46f
3030
webview_flutter: 9f491a9b5a66f2573946a389b2677987b0ff8c0b
3131

3232
PODFILE CHECKSUM: 8e679eca47255a8ca8067c4c67aab20e64cb974d
3333

34-
COCOAPODS: 1.10.1
34+
COCOAPODS: 1.11.2

example/ios/Runner.xcodeproj/project.pbxproj

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -335,7 +335,7 @@
335335
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
336336
GCC_WARN_UNUSED_FUNCTION = YES;
337337
GCC_WARN_UNUSED_VARIABLE = YES;
338-
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
338+
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
339339
MTL_ENABLE_DEBUG_INFO = NO;
340340
SDKROOT = iphoneos;
341341
TARGETED_DEVICE_FAMILY = "1,2";
@@ -414,7 +414,7 @@
414414
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
415415
GCC_WARN_UNUSED_FUNCTION = YES;
416416
GCC_WARN_UNUSED_VARIABLE = YES;
417-
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
417+
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
418418
MTL_ENABLE_DEBUG_INFO = YES;
419419
ONLY_ACTIVE_ARCH = YES;
420420
SDKROOT = iphoneos;
@@ -463,7 +463,7 @@
463463
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
464464
GCC_WARN_UNUSED_FUNCTION = YES;
465465
GCC_WARN_UNUSED_VARIABLE = YES;
466-
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
466+
IPHONEOS_DEPLOYMENT_TARGET = 9.0;
467467
MTL_ENABLE_DEBUG_INFO = NO;
468468
SDKROOT = iphoneos;
469469
TARGETED_DEVICE_FAMILY = "1,2";

example/lib/generated_plugin_registrant.dart

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
// Generated file. Do not edit.
33
//
44

5+
// ignore_for_file: directives_ordering
56
// ignore_for_file: lines_longer_than_80_chars
67

78
import 'package:video_player_web/video_player_web.dart';

example/lib/main.dart

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -104,9 +104,11 @@ const htmlData = r"""
104104
<li>a</li>
105105
<li>nested</li>
106106
<li>unordered
107-
<ol>
107+
<ol style="list-style-type: lower-alpha;" start="5">
108108
<li>With a nested</li>
109-
<li>ordered list.</li>
109+
<li>ordered list</li>
110+
<li>with a lower alpha list style</li>
111+
<li>starting at letter e</li>
110112
</ol>
111113
</li>
112114
<li>list</li>
@@ -269,23 +271,23 @@ class _MyHomePageState extends State<MyHomePage> {
269271
},
270272
tagsList: Html.tags..addAll(['tex', 'bird', 'flutter']),
271273
customRenders: {
272-
texMatcher(): CustomRender.fromWidget(widget: (context, buildChildren) => Math.tex(
274+
tagMatcher("tex"): CustomRender.widget(widget: (context, buildChildren) => Math.tex(
273275
context.tree.element?.innerHtml ?? '',
274276
mathStyle: MathStyle.display,
275277
textStyle: context.style.generateTextStyle(),
276278
onErrorFallback: (FlutterMathException e) {
277279
return Text(e.message);
278280
},
279281
)),
280-
birdMatcher(): CustomRender.fromInlineSpan(inlineSpan: (context, buildChildren) => TextSpan(text: "🐦")),
281-
flutterMatcher(): CustomRender.fromWidget(widget: (context, buildChildren) => FlutterLogo(
282+
tagMatcher("bird"): CustomRender.inlineSpan(inlineSpan: (context, buildChildren) => TextSpan(text: "🐦")),
283+
tagMatcher("flutter"): CustomRender.widget(widget: (context, buildChildren) => FlutterLogo(
282284
style: (context.tree.element!.attributes['horizontal'] != null)
283285
? FlutterLogoStyle.horizontal
284286
: FlutterLogoStyle.markOnly,
285287
textColor: context.style.color!,
286288
size: context.style.fontSize!.size! * 5,
287289
)),
288-
tableMatcher(): CustomRender.fromWidget(widget: (context, buildChildren) => SingleChildScrollView(
290+
tagMatcher("table"): CustomRender.widget(widget: (context, buildChildren) => SingleChildScrollView(
289291
scrollDirection: Axis.horizontal,
290292
child: tableRender.call().widget!.call(context, buildChildren),
291293
)),

example/pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name: example
22
description: flutter_html example app.
3-
3+
publish_to: none
44
version: 1.0.0+1
55

66
environment:

0 commit comments

Comments
 (0)