mirror of
https://github.com/gabehf/Fladder.git
synced 2026-03-14 17:55:58 -07:00
fix: FocusButton layering
This commit is contained in:
parent
5174bb3a6c
commit
1205b23a1b
1 changed files with 31 additions and 30 deletions
|
|
@ -150,40 +150,41 @@ class FocusButtonState extends State<FocusButton> {
|
||||||
},
|
},
|
||||||
onKeyEvent: _handleKey,
|
onKeyEvent: _handleKey,
|
||||||
child: ExcludeFocus(
|
child: ExcludeFocus(
|
||||||
child: FlatButton(
|
child: Stack(
|
||||||
onTap: widget.onTap,
|
children: [
|
||||||
onSecondaryTapDown: widget.onSecondaryTapDown,
|
FlatButton(
|
||||||
onLongPress: widget.onLongPress,
|
onTap: widget.onTap,
|
||||||
child: Stack(
|
onSecondaryTapDown: widget.onSecondaryTapDown,
|
||||||
children: [
|
onLongPress: widget.onLongPress,
|
||||||
ClipRRect(
|
child: widget.child,
|
||||||
borderRadius: FladderTheme.smallShape.borderRadius,
|
),
|
||||||
child: widget.child,
|
Positioned.fill(
|
||||||
),
|
child: ValueListenableBuilder(
|
||||||
Positioned.fill(
|
valueListenable: onHover,
|
||||||
child: ValueListenableBuilder(
|
builder: (context, value, child) => AnimatedOpacity(
|
||||||
valueListenable: onHover,
|
opacity: value ? 1 : 0,
|
||||||
builder: (context, value, child) => AnimatedOpacity(
|
duration: const Duration(milliseconds: 125),
|
||||||
opacity: value ? 1 : 0,
|
child: Stack(
|
||||||
duration: const Duration(milliseconds: 125),
|
children: [
|
||||||
child: Container(
|
IgnorePointer(
|
||||||
decoration: BoxDecoration(
|
child: Container(
|
||||||
color: Theme.of(context)
|
decoration: BoxDecoration(
|
||||||
.colorScheme
|
color: Theme.of(context)
|
||||||
.primaryContainer
|
.colorScheme
|
||||||
.withValues(alpha: widget.darkOverlay ? 0.1 : 0),
|
.primaryContainer
|
||||||
border: Border.all(width: 4, color: Theme.of(context).colorScheme.onPrimaryContainer),
|
.withValues(alpha: widget.darkOverlay ? 0.1 : 0),
|
||||||
borderRadius: FladderTheme.smallShape.borderRadius,
|
border: Border.all(width: 4, color: Theme.of(context).colorScheme.onPrimaryContainer),
|
||||||
|
borderRadius: FladderTheme.smallShape.borderRadius,
|
||||||
|
),
|
||||||
|
),
|
||||||
),
|
),
|
||||||
child: Stack(
|
...widget.overlays,
|
||||||
children: widget.overlays,
|
],
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
),
|
||||||
),
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue