The ultimate harness for coding agents and beyond. All your agents. All your machines. One command center. Start with code, then follow your curiosity and build across disciplines: CAD, circuits, robots, games and music.
TypeScript 3d-modelingagent-frameworkagent-harnessai-agentscadclaude-codecodexcoding-agentsdeveloper-toolsesp32game-developmentmcp-servermulti-agentopen-hardwareopencodeopenharnesspcbroboticsterminaltmux
feat(mobile): frosted glass under the floating mic, Search and +
Dev jacobbb0c6023dba1
diff --git a/mobile/lib/phone/floating_glass.dart b/mobile/lib/phone/floating_glass.dartnew file mode 100644index 000000000..f5c2748d0--- /dev/null+++ b/mobile/lib/phone/floating_glass.dart@@ -0,0 +1,67 @@+import 'dart:ui' show ImageFilter;++import 'package:flutter/material.dart';++import 'package:harness_mobile/shared/theme/app_theme.dart';++/// The resting fill of the terminal's floating buttons — the mic, Search and+/// `+`.+///+/// ⚠️ **Lighter than the terminal in both themes, because the terminal is dark+/// in both.** Every terminal palette is a near-black, so the dark theme's+/// surface grey laid over one at half strength drew a circle a few shades off+/// the page under it — the buttons read as missing. White at low strength is a+/// raised pane over that black; the light theme's is near-solid, as its+/// surfaces are.+Color get floatingButtonFill =>+ AppTheme.pick(const Color(0xD1FFFFFF), const Color(0x33FFFFFF));++/// The rim that draws the circle's edge over whatever runs under it.+Color get floatingButtonRim =>+ AppTheme.pick(const Color(0x29000000), const Color(0x59FFFFFF));++/// The resting shadow under those buttons: enough to lift the edge off a bright+/// line of output.+List<BoxShadow> get floatingButtonShadow => [+ BoxShadow(+ color: Colors.black.withValues(alpha: 0.3),+ blurRadius: 10,+ offset: const Offset(0, 3),+ ),+];++/// Frosted glass under a floating button: the output beneath [child] is+/// blurred to a soft wash, so its glyph reads against any line of text, while+/// the colour and movement of the terminal still show through.+///+/// ⚠️ **Blurred, not see-through.** A clear fill let every character under the+/// button cross its glyph, and the buttons were reported as too hard to see.+/// What the button covers is not readable any more — it was not readable+/// through a glyph either.+///+/// [child] is the circle itself and sets the size; the blur is clipped to it.+/// Grouped with the other floating buttons' blurs when a [BackdropGroup] is+/// above, so the backdrop is read once for all of them.+class FloatingGlass extends StatelessWidget {+ const FloatingGlass({super.key, required this.child});++ final Widget child;++ static const double blurSigma = 6;++ @override+ Widget build(BuildContext context) => Stack(+ alignment: Alignment.center,+ children: [+ Positioned.fill(+ child: ClipOval(+ child: BackdropFilter.grouped(+ filter: ImageFilter.blur(sigmaX: blurSigma, sigmaY: blurSigma),+ child: const SizedBox.expand(),+ ),+ ),+ ),+ child,+ ],+ );+}diff --git a/mobile/lib/phone/terminal_action_column.dart b/mobile/lib/phone/terminal_action_column.dartindex fec606a38..bea14c029 100644--- a/mobile/lib/phone/terminal_action_column.dart+++ b/mobile/lib/phone/terminal_action_column.dart@@ -4,6 +4,7 @@ import 'package:lucide_icons_flutter/lucide_icons.dart';import 'package:harness_mobile/shared/theme/app_theme.dart';import 'package:harness_mobile/terminal/terminal_session.dart';+import 'floating_glass.dart';import 'voice_input_controller.dart';import 'voice_mic_button.dart';import 'voice_mic_face.dart';@@ -83,6 +84,11 @@ class TerminalActionColumn extends StatelessWidget {Widget build(BuildContext context) {AppTheme.watch(context);final session = this.session;+ // One backdrop read for the three buttons' blurs — see [FloatingGlass].+ return BackdropGroup(child: _column(context, session));+ }++ Widget _column(BuildContext context, TerminalSession? session) {return Column(mainAxisSize: MainAxisSize.min,crossAxisAlignment: CrossAxisAlignment.end,@@ -194,22 +200,22 @@ class TerminalRoundAction extends StatelessWidget {duration: const Duration(milliseconds: 160),opacity: live ? 1 : 0.4,child: Center(- child: Container(- width: diameter,- height: diameter,- decoration: BoxDecoration(- shape: BoxShape.circle,- // The mic's resting look: see-through, so the output- // under the button stays readable, with a light shadow- // to keep the edge — see [floatingButtonFill].- color: floatingButtonFill,- border: Border.all(color: AppGlass.lift),- boxShadow: floatingButtonShadow,- ),- child: Icon(- icon,- size: 20,- color: AppPalette.textPrimary,+ // The mic's resting look — see [FloatingGlass].+ child: FloatingGlass(+ child: Container(+ width: diameter,+ height: diameter,+ decoration: BoxDecoration(+ shape: BoxShape.circle,+ color: floatingButtonFill,+ border: Border.all(color: floatingButtonRim),+ boxShadow: floatingButtonShadow,+ ),+ child: Icon(+ icon,+ size: 20,+ color: AppPalette.textPrimary,+ ),),),),diff --git a/mobile/lib/phone/voice_mic_face.dart b/mobile/lib/phone/voice_mic_face.dartindex c48986b15..6c42ccb09 100644--- a/mobile/lib/phone/voice_mic_face.dart+++ b/mobile/lib/phone/voice_mic_face.dart@@ -4,6 +4,7 @@ import 'package:lucide_icons_flutter/lucide_icons.dart';import 'package:harness_mobile/shared/theme/app_theme.dart';import 'package:harness_mobile/shared/widgets/pulse.dart';+import 'floating_glass.dart';import 'voice_mic_mode.dart';/// What the mic says it will do when tapped.@@ -49,20 +50,6 @@ Color voiceMicTint(VoiceMicFace face) => switch (face) {_ => AppPalette.accent,};-/// The resting fill of the terminal's floating buttons — the mic, Search and-/// `+` — see-through enough that the output under them stays readable.-Color get floatingButtonFill => AppGlass.surfaceFill.withValues(alpha: 0.5);--/// The resting shadow under those buttons: enough to lift the edge off the-/// text, light enough not to black out the characters beneath.-List<BoxShadow> get floatingButtonShadow => [- BoxShadow(- color: Colors.black.withValues(alpha: 0.2),- blurRadius: 8,- offset: const Offset(0, 2),- ),-];-/// The round, filled part of the mic: its colour, its glow, and the glyph for/// what a press will do.class VoiceMicCore extends StatelessWidget {@@ -77,7 +64,9 @@ class VoiceMicCore extends StatelessWidget {Color get _tint => voiceMicTint(face);@override- Widget build(BuildContext context) => AnimatedContainer(+ Widget build(BuildContext context) => FloatingGlass(child: _circle());++ Widget _circle() => AnimatedContainer(duration: const Duration(milliseconds: 220),curve: Curves.easeOutCubic,width: VoiceMicCore.diameter,@@ -93,7 +82,7 @@ class VoiceMicCore extends StatelessWidget {: null,color: lit ? null : floatingButtonFill,border: Border.all(- color: lit ? Colors.white.withValues(alpha: 0.28) : AppGlass.lift,+ color: lit ? Colors.white.withValues(alpha: 0.28) : floatingButtonRim,),// ⚠️ **Two different shadows for two different jobs, and the resting one// is not optional.** Lit, the button glows in its own colour — that is@@ -113,9 +102,8 @@ class VoiceMicCore extends StatelessWidget {offset: const Offset(0, 3),),]- // ⚠️ Light, and that is deliberate: the fill is see-through, and a- // box shadow paints under the WHOLE circle — a heavy one showed- // through as a dark disc over the very text the fill lets through.+ // ⚠️ Kept light: a box shadow paints under the WHOLE circle, and+ // the fill is not opaque — a heavy one showed through as a dark disc.: floatingButtonShadow,),child: Center(@@ -187,9 +175,8 @@ class VoiceMicRing extends StatelessWidget {height: VoiceMicCore.diameter,decoration: BoxDecoration(shape: BoxShape.circle,- color: voiceMicTint(- VoiceMicFace.listening,- ).withValues(alpha: 0.35 * (1 - t)),+ color: voiceMicTint(VoiceMicFace.listening)+ .withValues(alpha: 0.35 * (1 - t)),),),),