Repository: flutter
Issue: BUG: Elevated / Text / Outline Buttons - minimumSize not respected properly when visual density is not standard
Labels: framework,f: material design,d: api docs,has reproducible steps,P2,workaround available,found in release: 3.7,found in release: 3.9,team-design,triaged-design

## Steps to Reproduce

<!-- Please include full steps to reproduce so that we can reproduce the problem. -->

1. Execute `flutter run` on the code sample <!-- (see "Code sample" section below) -->

**Expected results:** All buttons and red container should have same height

**Actual results:** Buttons with VisualDensity compact and comfortable have a smaller height compared to the explicitly specified minimum height.

<details>
<summary>Code sample</summary>

<!--
      Please create a minimal reproducible sample that shows the problem
      and attach it below between the lines with the backticks.

      To create it you can use `flutter create bug` command and update the `main.dart` file.

      Alternatively, you can use https://dartpad.dev/
      which is capable of creating and running small Flutter apps.

      Without this we will unlikely be able to progress on the issue, and because of that
      we regretfully will have to close it.
-->

```dart
import 'package:flutter/material.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Flutter Demo',
      theme: ThemeData(primarySwatch: Colors.blue),
      home: const StlessHomePage(),
    );
  }
}

class StlessHomePage extends StatelessWidget {
  const StlessHomePage({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    const minHeight = 80.0;
    final buttonStyle = ElevatedButton.styleFrom(
      minimumSize: const Size(100, minHeight),
    );
    final standardButtonStyle = buttonStyle.copyWith(visualDensity: VisualDensity.standard);
    final comfortableButtonStyle = buttonStyle.copyWith(visualDensity: VisualDensity.comfortable);
    final compactButtonStyle = buttonStyle.copyWith(visualDensity: VisualDensity.compact);
    return Scaffold(
      appBar: AppBar(title: const Text('HomePage')),
      body: Center(
        child: Row(
          children: [
            const Spacer(),
            Container(width: 20, height: minHeight, color: Colors.red),
            ElevatedButton(style: standardButtonStyle, onPressed: () {}, child: const Text("Standard")),
            ElevatedButton(style: comfortableButtonStyle, onPressed: () {}, child: const Text("Comfortable")),
            ElevatedButton(style: compactButtonStyle, onPressed: () {}, child: const Text("Compact")),
            const Spacer(),
          ],
        ),
      ),
    );
  }
}
```

</details>

<details>
  <summary>Logs</summary>


<!-- Finally, paste the output of running `flutter doctor -v` here. -->

```
➜  bug_reporting_project flutter doctor -v
[✓] Flutter (Channel stable, 3.7.8, on macOS 13.2.1 22D68 darwin-arm64, locale en-GB)
    • Flutter version 3.7.8 on channel stable at /Users/alexandrudochioiu/.asdf/installs/flutter/3.7.8-stable
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 90c64ed42b (6 days ago), 2023-03-21 11:27:08 -0500
    • Engine revision 9aa7816315
    • Dart version 2.19.5
    • DevTools version 2.20.1

[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.1)
    • Android SDK at /Users/alexandrudochioiu/Library/Android/sdk
    • Platform android-33, build-tools 33.0.1
    • ANDROID_HOME = /Users/alexandrudochioiu/Library/Android/sdk
    • Java binary at: /Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 11.0.15+0-b2043.56-8887301)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 14.2)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 14C18
    • CocoaPods version 1.12.0

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2022.1)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 11.0.15+0-b2043.56-8887301)

[✓] IntelliJ IDEA Community Edition (version 2022.3.2)
    • IntelliJ at /Applications/IntelliJ IDEA CE.app
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart

[✓] VS Code (version 1.76.2)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.60.0

[✓] Connected device (3 available)
    • 2201116TG (mobile) • LN7DPFJ7MNZXPFFA • android-arm64  • Android 12 (API 31)
    • macOS (desktop)    • macos            • darwin-arm64   • macOS 13.2.1 22D68 darwin-arm64
    • Chrome (web)       • chrome           • web-javascript • Google Chrome 111.0.5563.110

[✓] HTTP Host Availability
    • All required HTTP hosts are available

• No issues found!

```

</details>

<img width="300" src="https://user-images.githubusercontent.com/38853913/227879497-6b7fac2c-016b-4af9-83a1-6f1995de8288.png">




<!--
      Consider also attaching screenshots and/or videos to better
      illustrate the issue.

      You can upload them directly on GitHub.
      Beware that video file size is limited to 10MB.
-->