Skip to content

Commit c2b79f8

Browse files
button: Give ZulipIconButton an optional tooltip param
1 parent 19f6b22 commit c2b79f8

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

lib/widgets/button.dart

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -240,10 +240,12 @@ class ZulipIconButton extends StatelessWidget {
240240
super.key,
241241
required this.icon,
242242
required this.onPressed,
243+
this.tooltip,
243244
});
244245

245246
final IconData icon;
246247
final VoidCallback onPressed;
248+
final String? tooltip;
247249

248250
@override
249251
Widget build(BuildContext context) {
@@ -258,6 +260,7 @@ class ZulipIconButton extends StatelessWidget {
258260
iconSize: 24,
259261
icon: Icon(icon),
260262
onPressed: onPressed,
263+
tooltip: tooltip,
261264
style: IconButton.styleFrom(
262265
tapTargetSize: MaterialTapTargetSize.shrinkWrap,
263266
fixedSize: Size.square(40),

0 commit comments

Comments
 (0)