show keys instead of toast

This commit is contained in:
Jonas Bark
2025-12-07 11:30:06 +01:00
parent eb07b78cce
commit d39af2c8ff

View File

@@ -63,9 +63,17 @@ class _TestbedState extends State<Testbed> with SingleTickerProviderStateMixin {
// Focus to receive key events without stealing focus from inputs.
late final FocusNode _focusNode;
bool _isMobile = false;
Offset? _lastMove;
@override
void didChangeDependencies() {
super.didChangeDependencies();
_isMobile = MediaQuery.sizeOf(context).width < 600;
}
@override
void initState() {
super.initState();
@@ -261,7 +269,7 @@ class _TestbedState extends State<Testbed> with SingleTickerProviderStateMixin {
if (widget.showKeyboard)
Positioned(
right: 12,
bottom: 12,
bottom: _isMobile ? 92 : 12,
child: IgnorePointer(
child: _KeyboardOverlay(
items: _keys,