Repository: flutter
Issue: Unicode arrow character → causes a 2.0 pixel RenderFlex overflow in the browser
Labels: framework,platform-web,has reproducible steps,team-framework,found in release: 3.27,found in release: 3.28

### Steps to reproduce

1. Run the attached code in the browser as a web app
2. Make the browser window vertically small enough that it starts to scroll vertically

Note: the error appears only in browser (tested with Chrome and Safari), when the specific Unicode arrow character is present in the indicated location.

The error does not appear on other platforms (iOS, macOS), and also does not appear when there is some other Unicode character (e.g emoji) or no Unicode characters in the indicated text.

### Expected results

There should be no RenderFlex overflow error

### Actual results

There is a RenderFlex overflow error:

<details open><summary>Error</summary>

```
══╡ EXCEPTION CAUGHT BY RENDERING LIBRARY ╞═════════════════════════════════════════════════════════
The following assertion was thrown during layout:
A RenderFlex overflowed by 1.00 pixels on the bottom.

The relevant error-causing widget was:
  Column Column:file:///Users/jaanus/Developer/Flutter/unicode_overflow_bug/lib/main.dart:62:30

To inspect this widget in Flutter DevTools, visit:
http://127.0.0.1:9100/#/inspector?uri=http%3A%2F%2F127.0.0.1%3A51147%2FG_wlOCLSzYs%3D&inspectorRef=inspector-0

The overflowing RenderFlex has an orientation of Axis.vertical.
The edge of the RenderFlex that is overflowing has been marked in the rendering with a yellow and
black striped pattern. This is usually caused by the contents being too big for the RenderFlex.
Consider applying a flex factor (e.g. using an Expanded widget) to force the children of the
RenderFlex to fit within the available space instead of being sized to their natural size.
This is considered an error condition because it indicates that there is content that cannot be
seen. If the content is legitimately bigger than the available space, consider clipping it with a
ClipRect widget before putting it in the flex, or using a scrollable container rather than a Flex,
like a ListView.
The specific RenderFlex in question is: RenderFlex#abccf relayoutBoundary=up19 OVERFLOWING:
  creator: Column ← Expanded ← Column ← IntrinsicHeight ← ConstrainedBox ← _SingleChildViewport ←
    IgnorePointer-[GlobalKey#67353] ← Semantics ← Listener ← _GestureSemantics ←
    RawGestureDetector-[LabeledGlobalKey<RawGestureDetectorState>#ed519] ← Listener ← ⋯
  parentData: offset=Offset(0.0, 104.0); flex=1; fit=FlexFit.tight (can use size)
  constraints: BoxConstraints(0.0<=w<=604.0, h=375.0)
  size: Size(604.0, 375.0)
  direction: vertical
  mainAxisAlignment: start
  mainAxisSize: min
  crossAxisAlignment: center
  verticalDirection: down
  spacing: 0.0
◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤◢◤
════════════════════════════════════════════════════════════════════════════════════════════════════
```
</details>

### Code sample

<details open><summary>Code sample</summary>

```dart
import 'package:flutter/material.dart';
import 'package:go_router/go_router.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  @override
  Widget build(BuildContext context) {
    final router = GoRouter(
      routes: [
        GoRoute(
          path: '/',
          builder: (context, state) => const RootRoute(),
        ),
      ],
    );

    return MaterialApp.router(
      routerConfig: router,
    );
  }
}

class RootRoute extends StatelessWidget {
  const RootRoute({super.key});

  @override
  Widget build(BuildContext context) => const AppPage();
}

class AppPage extends StatelessWidget {
  const AppPage({
    super.key,
  });

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      body: LayoutBuilder(
        builder: (context, constraints) {
          return SingleChildScrollView(
            child: ConstrainedBox(
              constraints: BoxConstraints(
                minHeight: constraints.maxHeight,
              ),
              // color: theme.colors.orange,
              child: IntrinsicHeight(
                child: Column(
                  crossAxisAlignment: CrossAxisAlignment.center,
                  children: [
                    Padding(
                      padding: EdgeInsets.only(
                        top: 32,
                      ),
                      child: _Header(),
                    ),
                    Expanded(
                      child: Column(
                        mainAxisSize: MainAxisSize.min,
                        children: [
                          const Spacer(),
                          Padding(
                            padding: EdgeInsets.only(top: 32.0),
                            child: Row(
                              mainAxisAlignment: MainAxisAlignment.center,
                              children: [
                                Container(
                                  color: Colors.yellow,
                                  height: 256,
                                  width: 128,
                                ),
                              ],
                            ),
                          ),
                          Padding(
                            padding: const EdgeInsets.only(top: 24.0),
                            child: Container(
                              color: Colors.green,
                              width: 256,
                              height: 64,
                            ),
                          ),
                          const Spacer(),
                        ],
                      ),
                    ),
                    Padding(
                      padding: EdgeInsets.symmetric(
                        vertical: 32,
                      ),
                      child: Container(
                        color: Colors.blue,
                        width: 128,
                        height: 128,
                      ),
                    ),
                  ],
                ),
              ),
            ),
          );
        },
      ),
    );
  }
}

class _Header extends StatelessWidget {
  const _Header();

  @override
  Widget build(BuildContext context) {
    return Column(
      mainAxisSize: MainAxisSize.min,
      children: [
        SizedBox(height: 32),
        _BorderedButton(
          label: Text(
            // This gives the RenderFlex overflow error
            "More →",

            // This does NOT give the error
            // "More 😀",

            // This does NOT give the error either
            // "More",
          ),
          onTap: () {},
        ),
      ],
    );
  }
}

class _BorderedButton extends StatelessWidget {
  const _BorderedButton({
    required this.label,
    required this.onTap,
  });

  final Widget label;
  final Function() onTap;

  @override
  Widget build(BuildContext context) {
    return InkWell(
      onTap: onTap,
      child: Container(
        decoration: BoxDecoration(
          border: Border.all(
            color: Colors.black,
          ),
          borderRadius: BorderRadius.circular(6),
        ),
        child: Padding(
          padding: EdgeInsets.all(8),
          child: label,
        ),
      ),
    );
  }
}

```

</details>


### Screenshots or Video

<details open>
<summary>Screenshots / Video demonstration</summary>

<img width="708" alt="Image" src="https://github.com/user-attachments/assets/bc24e21d-b550-4fb4-96ef-a29fe2da3bea" />

</details>


### Logs

<details open><summary>Logs</summary>

```console
[Paste your logs here]
```

</details>


### Flutter Doctor output

<details open><summary>Doctor output</summary>

```console
jaanus@studio ~/D/F/unicode_overflow_bug (main)> flutter doctor -v
[✓] Flutter (Channel stable, 3.27.2, on macOS 15.2 24C101 darwin-arm64, locale et-EE)
    • Flutter version 3.27.2 on channel stable at /Users/jaanus/fvm/versions/3.27.2
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 68415ad1d9 (8 days ago), 2025-01-13 10:22:03 -0800
    • Engine revision e672b006cb
    • Dart version 3.6.1
    • DevTools version 2.40.2

[✓] Android toolchain - develop for Android devices (Android SDK version 35.0.0)
    • Android SDK at /Users/jaanus/Library/Android/sdk
    • Platform android-35, build-tools 35.0.0
    • ANDROID_HOME = /Users/jaanus/Library/Android/sdk
    • Java binary at: /Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 21.0.4+-12422083-b607.1)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 16.2)
    • Xcode at /Applications/Xcode-16.2.app/Contents/Developer
    • Build 16C5032a
    • CocoaPods version 1.16.2

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2024.2)
    • 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 21.0.4+-12422083-b607.1)

[✓] VS Code (version 1.96.4)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.102.0

[✓] Connected device (4 available)
    • JK iPhone 15 Pro (mobile)       • 00008130-000431810238001C • ios            • iOS 18.2.1 22C161
    • macOS (desktop)                 • macos                     • darwin-arm64   • macOS 15.2 24C101 darwin-arm64
    • Mac Designed for iPad (desktop) • mac-designed-for-ipad     • darwin         • macOS 15.2 24C101 darwin-arm64
    • Chrome (web)                    • chrome                    • web-javascript • Google Chrome 131.0.6778.265
    ! Error: Browsing on the local area network for JK iPhone 11 Pro. Ensure the device is unlocked and attached with a cable or
      associated with the same local area network as this Mac.
      The device must be opted into Developer Mode to connect wirelessly. (code -27)

[✓] Network resources
    • All expected network resources are available.

• No issues found!
```

</details>