mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2025-01-10 12:44:31 +00:00
center desktop tor button in menu
This commit is contained in:
parent
cd00e9f8fd
commit
eff2d7d539
1 changed files with 45 additions and 39 deletions
|
@ -120,50 +120,56 @@ class _DesktopTorStatusButtonState extends ConsumerState<DesktopTorStatusButton>
|
|||
.extension<StackColors>()!
|
||||
.getDesktopMenuButtonStyle(context),
|
||||
onPressed: widget.onPressed,
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.symmetric(
|
||||
vertical: 16,
|
||||
),
|
||||
child: Row(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
AnimatedContainer(
|
||||
duration: widget.transitionDuration,
|
||||
width: _iconOnly ? 0 : 16,
|
||||
child: Row(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsets.symmetric(
|
||||
vertical: 16,
|
||||
),
|
||||
SvgPicture.asset(
|
||||
Assets.svg.tor,
|
||||
color: _color(_torConnectionStatus),
|
||||
width: 20,
|
||||
height: 20,
|
||||
),
|
||||
AnimatedOpacity(
|
||||
duration: widget.transitionDuration,
|
||||
opacity: _iconOnly ? 0 : 1.0,
|
||||
child: SizeTransition(
|
||||
sizeFactor: animationController,
|
||||
axis: Axis.horizontal,
|
||||
axisAlignment: -1,
|
||||
child: SizedBox(
|
||||
width: labelLength,
|
||||
child: Row(
|
||||
children: [
|
||||
const SizedBox(
|
||||
width: 12,
|
||||
),
|
||||
Text(
|
||||
_torConnectionStatus.name.capitalize(),
|
||||
style: STextStyles.smallMed12(context).copyWith(
|
||||
color: _color(_torConnectionStatus),
|
||||
child: Row(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
AnimatedContainer(
|
||||
duration: widget.transitionDuration,
|
||||
width: _iconOnly ? 0 : 16,
|
||||
),
|
||||
SvgPicture.asset(
|
||||
Assets.svg.tor,
|
||||
color: _color(_torConnectionStatus),
|
||||
width: 20,
|
||||
height: 20,
|
||||
),
|
||||
AnimatedOpacity(
|
||||
duration: widget.transitionDuration,
|
||||
opacity: _iconOnly ? 0 : 1.0,
|
||||
child: SizeTransition(
|
||||
sizeFactor: animationController,
|
||||
axis: Axis.horizontal,
|
||||
axisAlignment: -1,
|
||||
child: Row(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
const SizedBox(
|
||||
width: 12,
|
||||
),
|
||||
),
|
||||
],
|
||||
Text(
|
||||
_torConnectionStatus.name.capitalize(),
|
||||
style: STextStyles.smallMed12(context).copyWith(
|
||||
color: _color(_torConnectionStatus),
|
||||
),
|
||||
),
|
||||
const SizedBox(
|
||||
width: 21,
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue