chore: Add tooltip to links in html
This commit is contained in:
parent
eecf206eb8
commit
4072e99696
1 changed files with 14 additions and 13 deletions
|
|
@ -182,21 +182,22 @@ class HtmlMessage extends StatelessWidget {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return WidgetSpan(
|
return WidgetSpan(
|
||||||
child: InkWell(
|
child: Tooltip(
|
||||||
splashColor: Colors.transparent,
|
message: href,
|
||||||
onTap: () =>
|
child: InkWell(
|
||||||
UrlLauncher(context, node.attributes['href'], node.text)
|
splashColor: Colors.transparent,
|
||||||
.launchUrl(),
|
onTap: () => UrlLauncher(context, href, node.text).launchUrl(),
|
||||||
child: Text.rich(
|
child: Text.rich(
|
||||||
TextSpan(
|
TextSpan(
|
||||||
children: _renderWithLineBreaks(
|
children: _renderWithLineBreaks(
|
||||||
node.nodes,
|
node.nodes,
|
||||||
context,
|
context,
|
||||||
depth: depth,
|
depth: depth,
|
||||||
|
),
|
||||||
|
style: linkStyle,
|
||||||
),
|
),
|
||||||
style: linkStyle,
|
style: const TextStyle(height: 1.25),
|
||||||
),
|
),
|
||||||
style: const TextStyle(height: 1.25),
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue