File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -21,15 +21,21 @@ extension IsLinkTag on html.Element {
2121 bool get hasTextAlign {
2222 return outerHtml.contains ("text-align" );
2323 }
24+
25+ bool get hasUnderline {
26+ return outerHtml.contains ("text-decoration: underline" );
27+ }
2428}
2529
2630extension CustomHtmlStylesX on BuildContext {
2731 Map <String , String >? customStylesBuilder (html.Element element) {
2832 return {
29- if (! element.hasTextAlign) "text-align" : "justify " ,
33+ if (! element.hasTextAlign) "text-align" : "left " ,
3034 if (element.isH1) "font-size" : "20px" ,
31- if (element.isLink) "color" : colorTheme.orangePomegranade.htmlFormat,
32- "text-decoration-color" : colorTheme.orangePomegranade.htmlFormat,
35+ if (element.isLink) "color" : colorTheme.orangePomegranade.hexString,
36+ "text-decoration-color" : colorTheme.orangePomegranade.hexString,
37+ if (element.hasUnderline)
38+ "text-decoration-color" : colorTheme.blackMirage.hexString,
3339 };
3440 }
3541}
You can’t perform that action at this time.
0 commit comments