refactor(ui): Use IconButton's tooltip method instead of the Tooltip widget in BrandHeroScreen
This commit is contained in:
parent
5cfeb8aba8
commit
104beea2d6
|
@ -142,32 +142,30 @@ class _HeroSliverAppBarState extends State<HeroSliverAppBar> {
|
|||
if (widget.hasFlashButton && isMobile)
|
||||
AnimatedSwitcher(
|
||||
duration: const Duration(milliseconds: 300),
|
||||
child: Tooltip(
|
||||
message: 'jobs.title'.tr(),
|
||||
child: IconButton(
|
||||
onPressed: () {
|
||||
showModalBottomSheet(
|
||||
context: context,
|
||||
useRootNavigator: true,
|
||||
isScrollControlled: true,
|
||||
builder: (final BuildContext context) =>
|
||||
DraggableScrollableSheet(
|
||||
expand: false,
|
||||
maxChildSize: 0.9,
|
||||
minChildSize: 0.4,
|
||||
initialChildSize: 0.6,
|
||||
builder: (final context, final scrollController) =>
|
||||
JobsContent(controller: scrollController),
|
||||
),
|
||||
);
|
||||
},
|
||||
icon: Icon(
|
||||
isJobsListEmpty ? Ionicons.flash_outline : Ionicons.flash,
|
||||
),
|
||||
color: isJobsListEmpty
|
||||
? Theme.of(context).colorScheme.onBackground
|
||||
: Theme.of(context).colorScheme.primary,
|
||||
child: IconButton(
|
||||
onPressed: () {
|
||||
showModalBottomSheet(
|
||||
context: context,
|
||||
useRootNavigator: true,
|
||||
isScrollControlled: true,
|
||||
builder: (final BuildContext context) =>
|
||||
DraggableScrollableSheet(
|
||||
expand: false,
|
||||
maxChildSize: 0.9,
|
||||
minChildSize: 0.4,
|
||||
initialChildSize: 0.6,
|
||||
builder: (final context, final scrollController) =>
|
||||
JobsContent(controller: scrollController),
|
||||
),
|
||||
);
|
||||
},
|
||||
icon: Icon(
|
||||
isJobsListEmpty ? Ionicons.flash_outline : Ionicons.flash,
|
||||
),
|
||||
color: isJobsListEmpty
|
||||
? Theme.of(context).colorScheme.onBackground
|
||||
: Theme.of(context).colorScheme.primary,
|
||||
tooltip: 'jobs.title'.tr(),
|
||||
),
|
||||
),
|
||||
const SizedBox.shrink(),
|
||||
|
|
Loading…
Reference in New Issue