Files
alan 04ba81e0ea Remove Cupertino chat cleanup leftovers
Keep chat and folder-picker UI on the Material path by removing obsolete Cupertino imports, icon metadata, flags, and alternate control handling while preserving existing behavior and focused test coverage.
2026-11-11 20:06:37 +00:00

26 lines
1.0 KiB
Dart

import 'package:flutter/material.dart';
import 'chat_bar_tint.dart';
/// The conversation bar's model and mode controls read as the bar's other
/// actions do: neutral, not tinted like a primary call to action. In a
/// coloured chat's bar they take its foreground ([ChatBarTintScope]) instead.
///
/// Material: a [TextButton] style in the role the bar's icon buttons use
/// (`onSurfaceVariant`).
ButtonStyle chatBarTextButtonStyle(
BuildContext context, {
bool compact = false,
}) => TextButton.styleFrom(
foregroundColor:
ChatBarTintScope.foregroundOf(context) ??
Theme.of(context).colorScheme.onSurfaceVariant,
// The same 12 px each side as an icon button's glyph inside its 48 px
// target, so text sits off its hover/press shape as it does top and bottom.
padding: compact ? null : chatBarButtonPadding,
minimumSize: compact ? null : const Size.square(kMinInteractiveDimension),
);
/// Horizontal padding inside the bar's text buttons (model, mode).
const EdgeInsets chatBarButtonPadding = EdgeInsets.symmetric(horizontal: 12);