ResponsiveFramework
ResponsiveFramework copied to clipboard
Any way to remove space next to AppBar Title when leading is hidden?
If you add the ResponsiveVisibility to an AppBar's 'leading' when you hide it, it takes up space with the "SizedBox.shrink". Since it won't be removed unless null.
leading: ResponsiveVisibility(
hiddenWhen: const [Condition.largerThan(name: TABLET)],
child: IconButton(
icon: const Icon(Icons.menu),
onPressed: () {},
),
),
But you can't assign null to a widget to disable it:
leading: ResponsiveVisibility(
replacement: null,
hiddenWhen: const [Condition.largerThan(name: TABLET)],
child: IconButton(
icon: const Icon(Icons.menu),
onPressed: () {},
),
),
So is there any way to remove the space next to the title when leading is hidden?